I'm trying to run a node js script on aws lambda that uses ffmpeg. To do this, I need to install ffmpeg on the machine itself.
I have looked trhough the documentation but I could not find how to connect to the machine that runs the lambda.
This works for me in Python:
tar -zxvf ffmpeg-release-amd64-static.tar.xz
ffmpeg
(and optionally ffprobe
) from folder.cd
into this folder and zip with zip -r -X "../archive.zip" *
Set the correct filepath to ffmpeg like so:
FFMPEG_STATIC = "/var/task/ffmpeg"
import subprocess
subprocess.call([FFMPEG_STATIC, '-i', input_file, output_file])
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With