Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- rtmp {
- server {
- listen 1935;
- chunk_size 4096;
- application live {
- live on;
- record off;
- # No RTMP playback
- deny play all;
- push rtmp://127.0.0.1:1935/hls-live;
- push rtmp://127.0.0.1:1935/dash-live;
- on_publish http://127.0.0.1:8090/rest/live/on_publish;
- on_publish_done http://127.0.0.1:8090/rest/live/on_publish_done ;
- }
- application hls-live {
- live on;
- # No RTMP playback
- deny play all;
- # Only allow publishing from localhost
- allow publish 127.0.0.1;
- deny publish all;
- # Package this stream as HLS
- hls on;
- hls_path /var/www/live_hls;
- hls_fragment 3;
- hls_playlist_length 60;
- # Put streams in their own subdirectory under `hls_path`
- hls_nested on;
- hls_fragment_naming system;
- }
- application dash-live {
- live on;
- # No RTMP playback
- deny play all;
- # Only allow publishing from localhost
- allow publish 127.0.0.1;
- deny publish all;
- # Package this stream as DASH
- dash on;
- dash_path /var/www/live_dash;
- dash_fragment 5;
- dash_playlist_length 60;
- # Put streams in their own subdirectory under `dash_path`
- dash_nested on;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement