OpenFaaS Transcode Pipeline
This repo consists of a series of functions built for OpenFaaS.
I have a large movie collection that I want to upload into Plex. Since modern Blue-Ray movies are quite large I wanted an easy way to transcode them down to a smaller size while still retaining quality. The series of functions in this repo allows me to do just that is a very automated fashion.
Functions (in order)
This is the entrypoint into the pipeline that is used to start he process. You can also add things like Slack integration calls here.
This is the main worker for the pipleine. The worker is called using the
/async-function endpoint. This allows the transcoding to take hours without holding up adding new media to the backlog. Since NATS is used the backgroud we can pull media off the queue when once is done. The transcoding itself is done by a great Ruby executable found here. Huge shoutout to donmelton for making a great library.
- Download the media from the
- Transcode the media into
- Upload the finished file to the
- Delete the raw file from the local container
This step moves the completed media file from the
complete Minio bucket to another Minio server or your choice.
- Downlaod from the
- Upload to the
mediabucket on another server
This is the cleanup step.
- Check for the presence of the media at the final destination
- Delete the media from the
trancdoebuckets on the other server