Created
November 24, 2021 19:42
-
-
Save ford-prefect/46c0b0bd4e3985852047ddd648a9f3ff to your computer and use it in GitHub Desktop.
nginx-rtmp-docker config
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
worker_processes auto; | |
rtmp_auto_push on; | |
events {} | |
rtmp { | |
server { | |
listen 1935; | |
listen [::]:1935 ipv6only=on; | |
application live { | |
live on; | |
hls on; | |
hls_path /tmp/hls; | |
record off; | |
} | |
} | |
} | |
http { | |
server { | |
listen 80; | |
listen [::]:80 ipv6only=on; | |
location /hls { | |
types { | |
application/vnd.apple.mpegurl m3u8; | |
} | |
root /tmp; | |
add_header Cache-Control no-cache; | |
# To avoid issues with cross-domain HTTP requests (e.g. during development) | |
add_header Access-Control-Allow-Origin *; | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment