Skip to main content

External writer

The external writer allows you to build your own custom outputs using any of the external writer compatible outputs.

You will have to set a protocol handler, and if it matches MistServer will provide the requested stream output into the commandline through standard input. Any info will be printed to standard out and log messages go to standard error.

OptionDescription
Human Readable NameThis is the name to later identify the external writer you made.
CommandlineThis is the command line (with optional arguments) that will be run as the writer.
URI protocols handledWhich protocol handlers are used to identify when MistServer should use the commandline.

The external writer cannot overwrite the output handlers already available within MistServer. As an example adding rtmp as a handler will not trigger the external writer as MistServer already handles that through the RTMP output. You could however use rtmp-new:// instead.

Examples

basic HTTP upload

MistServer by itself does not support HTTP post. However you could simply add it by creating an external writer with the following command line:

OptionDescription
Human Readable Namehttp-put
Command linecurl -T -
URI protocols handledhttp

This would allow you to write any external writer compatible output as HTTP put when you try to push towards http://server.com/file.ext.

S3 compatible upload

Mistserver currently does not support S3, luckily our friends at Livepeer have created an external writer specifically for S3 storage upload. It is available here.

OptionDescrption
Human Readable NameS3 upload
Command line/path/to/livepeer-catalyst-uploader
Uri protocols handleds3+http, s3 , s3+https

For more instructions on how to use it see the README available on github.

To make the S3 usage easier we would recommend creating custom variables containing the S3 account & bucket location.

Example push towards S3 using the livepeer-catalyst-uploader:

Source: streamname
Target: s3+https://${s3acc}@${s3path}/$basename/$year_$month_$day_$hour_$minute_$seconds.ext

  • ${s3acc} would be the AWS_KEY:AWS_SECRET
  • ${s3path} would be the s3address.com/bucket/
    • Keep in mind that the address should be without any scheme (http:// or https://) as the beginning portion of the push target already has the scheme.

For possible push methods please look at our pushing documentation.