Open Source Cloud Encoder for FFmpeg
A distributed and scalable video encoding pipeline to be used as an API or web interface using your own hosted infrastructure and FFmpeg encoding presets.
- HTTP API for submitting jobs to an redis-backed FFmpeg worker
- S3 storage (AWS and Digital Ocean)
- Web Dashboard UI for managing encode jobs
- Machines UI/API for scaling worker instances
- Database stored FFmpeg encoding presets
- User accounts and roles
- Docker
- Go 1.11+
- NodeJS 8+ (For web dashboard)
- FFmpeg
- Postgres
- S3 API Credentials & Bucket (AWS or Digital Ocean)
- Digital Ocean API Key (only required for Machines API)
Docker is optional, but highly recommended for this setup. This guide assumes you are using Docker.
- Start Redis and Postgres in Docker:
docker-compose up -d redis
docker-compose up -d db
When the database container runs for the first time, it will create a persistent volume as /var/lib/postgresql/data
. It will also run the scripts in scripts/
to create the database, schema, settings and presets.
- Set environment variables in
docker-compose.yml
.
Environment variables will override defaults set in config/default.yml
.
- Build & start API server:
go build -v && openencoder.exe server
- Build & start worker:
go build -v && openencoder.exe worker
- Start Web Dashboard for development:
cd static && npm run serve
curl -X POST \
http://localhost:8080/api/jobs \
-H 'Content-Type: application/json' \
-d '{
"preset": "h264_baseline_360p_600",
"source": "s3:///src/ToS-1080p.mp4",
"dest": "s3:///dst/tears-of-steel/"
}'
See API.md for full jobs API documentation.
See: API.md
You can scale workers by adding more machines via the Web UI or API.
Currently only Digital Ocean
is supported. More providers are planned.
See: API.md for Machines API documentation.
See: wiki for more documentation.
See: Development Project for current development tasks and status.
MIT