52 lines
1.3 KiB
Plaintext
52 lines
1.3 KiB
Plaintext
map $http_upgrade $connection_upgrade {
|
||
default upgrade;
|
||
'' close;
|
||
}
|
||
|
||
server{
|
||
listen $WEBSOCKET_PORT ssl;
|
||
ssl_certificate $JC_CERT/fullchain.pem;
|
||
ssl_certificate_key $JC_CERT/privkey.pem;
|
||
|
||
location / {
|
||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||
proxy_set_header Host $host;
|
||
proxy_pass http://$NET$WEBSERVER:9000;
|
||
proxy_http_version 1.1;
|
||
proxy_set_header Upgrade $http_upgrade;
|
||
proxy_set_header Connection "upgrade";
|
||
proxy_read_timeout 120s;
|
||
}
|
||
}
|
||
|
||
server {
|
||
listen 443 ssl;
|
||
listen [::]:443 ssl;
|
||
server_name $JC_SERVICE;
|
||
ssl_certificate $JC_CERT/fullchain.pem;
|
||
ssl_certificate_key $JC_CERT/privkey.pem;
|
||
|
||
location / {
|
||
client_max_body_size 0;
|
||
proxy_pass http://$ENDPOINT;
|
||
proxy_set_header Host 'soundbase.radiodemo.oma-radio.fr';
|
||
proxy_set_header X-Forwarded-Host $JC_SERVICE;
|
||
proxy_set_header X-Forwarded-Proto https;
|
||
proxy_set_header X-Forwarded-For $remote_addr;
|
||
}
|
||
|
||
|
||
location /direct.ogg {
|
||
client_max_body_size 0;
|
||
proxy_pass http://$NET$ICECAST:8000/direct.ogg;
|
||
}
|
||
location /direct.mp3 {
|
||
client_max_body_size 0;
|
||
proxy_pass http://$NET$ICECAST:8000/direct.mp3;
|
||
}
|
||
|
||
# TODO open some stat route
|
||
|
||
|
||
}
|