[FFmpeg-user] FFMPEG output to HTTP

Farid Zakaria farid.m.zakaria at gmail.com
Mon Jan 25 22:44:32 CET 2016


Hello,

I'm wondering if its possible for ffmpeg to output to S3 ?
The idea here is that I'd like to have the input from HTTP and write it
back via POST/PUT to another http endpoint.

The "real use case" is using S3 https://aws.amazon.com/s3/ and the ability
to provide "pre-signed urls" (temporary urls providing upload access)

Here is the sample command I tried

> ffmpeg -y -i
https://s3.amazonaws.com/myfake-bucket/sample.mp4 -codec:v libx264
-profile:v high -preset slow -f mp4 "
https://myfake-bucket.s3.amazonaws.com/output.mp4?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIM6U6GTEIXT3QXLQ%2F20160125%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20160125T213822Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=29edc68cce9d8a4fbc9a7dcad23b2fd19aea28b11b71a44f68f93c85e4dfbf1e
"

It seems to grab the video fine from the input but fails at writing it to
the HTTP output. I know that the URL I'm generating is correct by
validating it via an upload through cURL

>  curl -H "Content-Type:video/mp4" -v --upload-file ~/Downloads/sample.mp4
-X PUT "
https://slinger-test.s3.amazonaws.com/output.mp4?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIM6U6GTEIXT3QXLQ%2F20160125%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20160125T212850Z&X-Amz-Expires=300&X-Amz-SignedHeaders=host&X-Amz-Signature=0cc129936b839c238b9338cda11328acff82eb473273ea3b13095835c22d92b3
"
Farid Zakaria


More information about the ffmpeg-user mailing list