transcode #25

Supports: precise
Add to new model


Video transcoding is a complicated, resource intensive options.
This charm breaks a video into N chunks, and farms out video transcoding
to N workers. It can take video files of many different types. The output
will always be a web-viewable .mp4, using h264 and aac codecs.


This charm will transcode videos of basically any format and codec, to an HTML5-compatible mp4 file, using the h264 video codec, and the aac audio codec.


  • Install

juju deploy nfs
juju deploy -n 4 transcode
juju add-relation nfs transcode

  • Copy a video file into any node's /srv/ directory

  • The results will be in the /srv/ directory, with a file ending in .mp4

  • You can watch the progress, view, and download the output by pointing a web browser at any node

Scale out Usage

The performance of the transcoding will scale linearly, with the number of transcode units. For instance, a video that takes 10 minutes to transcode with a single node, will transcode in 1 minute with 10 nodes.

juju add-unit -n 10 transcode


  • Update the input_url and/or output_size configuration variables

juju set transcode input_url=/srv/foo.avi output_size=copy
juju set transcode input_url=
juju set transcode input_url= output_size=960x540
juju set transcode input_url= output_size=640x360

Known Limitations and Issues

This charm currently supports transcoding most formats to mp4/h264/aac, and scaling the video to a different size. There are a few non-free formats (e.g. divx) which are not easily supported on Linux.

Contact Information

This charm was written by Dustin Kirkland, and uses libav for transcoding.

Upstream Project Name


(string) input file; path to local file in /srv, or remote URL to fetch
(string) output frame size, see avconv(1)