Installation
The DASH live source simulator is a web service and is run using wsgi.
Since wsgi is cross-platform it should work with multiple HTTP servers like Apache and nginx. The DASH-IF instance at
https://livesim.dashif.org is run using Apache in AWS.
For local testing, it is also possible to run the wsgi server itself by calling the script tools/run_wsgi_server.sh
.
Python 3.6 or later, Apache2 with mod_wsgi or mod_python (can also be run without Apache, or with nginx).
The VoD content (in live profile) that serves as raw content for live should typically be at
/var/www/html/dash/vod
The directory is specified as CONTENT_ROOT
to the simulator.
The main issue for browser players like dash.js is typically CORS.
For serving files using Apache2 from /var/www/html/dash/vod it is recommended to add the file
dash.conf to the Apache2 configuration. The location depends on distribution, but in CentOS it is /etc/httpd/conf.d/dash.conf
.
This is the recommended way to run on a public server. For testing, it may easier to run a local server, see below. How mod_wsgi is installed depends on the Linux distribution.
The mod_wsgi configuration goes into the configuration directory (for CentOS)
/etc/httpd/conf.d/mod_wsgi/dashlivesim.conf
or something similar on other Linux distributions.
As seen in the example file provided in this directory, VOD_CONF_DIR
and CONTENT_ROOT
must be set up,
and the path to the directory containing the dashlivesim
package and the Python module mod_wsgi/mod_dashlivesim.py
must be specified.
For Apache2, the mod_wsgi module is needed. You also then need configure paths to use the code, e.g.
using a file mod_wsgi_dashlivesim" in
/etc/httpd/conf.d/` with content like:
SGIScriptAlias /livesim /usr/local/bin/mod_wsgi/dashlivesim/mod_wsgi/mod_dashlivesim.py
WSGIPythonPath /usr/local/bin/mod_wsgi
setEnv VOD_CONF_DIR /var/www/html/dash/vod_configs
setEnv CONTENT_ROOT /var/www/html/dash/vod
To run a local wsgi http server use the script tools/run_wsgi_server
. The vod_config
and content_root
directories need to specified on the command line.
For each simulated live source directory containing manifest files , there must be a configuration file with the corresponding name .cfg
For example, for testpic_2s there is a file
<VOD_CONF_DIR>/testpic_2s.cfg
For files without subtitles, it can be automatically generated by running the tool
tools/run_vodanalyzer.sh
This runs the Python script dashlivesim.vodanalyzer.dashanalyzer
and produces a file <content>.cfg
.
You can then edit the file, to include fewer segments, fewer representations, or more representations if there
are other manifests that contain other representations. In particular, all subtitle representations must be added by hand.
The corresponding content resides in
<CONTENT_DIR>/<content>/
In such a directory there should one or more VoD MPDs and associated media files. Note that the file extensions are critical, but the base names not.
[contentName]
-> [Manifest].mpd
-> [rep1]
-> [init].mp4
-> [seqNr].m4s
-> [rep2]
...
For UTCTiming head mode to work, there must be file accessible via http:///dash/time.txt``. The content is not relevant. The CORS support for the header Date must be supported.
Sample content is available at http://livesim.dashif.org/dash/vod/. Sample configurations are available at http://livesim.dashif.org/dash/vod_configs/
DASH-IF is hosting a server as http://livesim.dashif.org, see test URLs.