add domain configurations
This commit is contained in:
41
deploy/nginx/nyone-hls.conf
Normal file
41
deploy/nginx/nyone-hls.conf
Normal file
@@ -0,0 +1,41 @@
|
||||
# HLS reverse proxy for MediaMTX.
|
||||
# Browser origin is https://nyone.net, while playback URLs point here:
|
||||
# https://nyone-hls.net/<channel-slug>/index.m3u8
|
||||
|
||||
server {
|
||||
listen 80;
|
||||
listen [::]:80;
|
||||
server_name nyone-hls.net;
|
||||
|
||||
return 301 https://$host$request_uri;
|
||||
}
|
||||
|
||||
server {
|
||||
listen 443 ssl http2;
|
||||
listen [::]:443 ssl http2;
|
||||
server_name nyone-hls.net;
|
||||
|
||||
ssl_certificate /etc/letsencrypt/live/nyone-hls.net/fullchain.pem;
|
||||
ssl_certificate_key /etc/letsencrypt/live/nyone-hls.net/privkey.pem;
|
||||
include /etc/letsencrypt/options-ssl-nginx.conf;
|
||||
ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem;
|
||||
|
||||
access_log /var/log/nginx/nyone-hls.access.log;
|
||||
error_log /var/log/nginx/nyone-hls.error.log;
|
||||
|
||||
location / {
|
||||
proxy_pass http://127.0.0.1:19988;
|
||||
proxy_http_version 1.1;
|
||||
proxy_set_header Host $host;
|
||||
proxy_set_header X-Real-IP $remote_addr;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
proxy_set_header X-Forwarded-Proto https;
|
||||
|
||||
proxy_buffering off;
|
||||
proxy_request_buffering off;
|
||||
proxy_read_timeout 60s;
|
||||
proxy_send_timeout 60s;
|
||||
|
||||
add_header Cache-Control "no-store, no-cache, must-revalidate, proxy-revalidate" always;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user