taiko-web/docker/taiko-web-nginx.conf

29 lines
643 B
Plaintext
Raw Normal View History

2019-06-01 23:01:50 +08:00
server {
listen 80;
server_name _;
server_tokens off;
location / {
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header Host $server_name;
proxy_read_timeout 7200s;
proxy_pass http://127.0.0.1:34801;
proxy_max_temp_file_size 50000m;
}
location ~ ^/(assets|songs|src)/ {
root /taiko-web/public;
location ~ ^/songs/([0-9]+)/preview\.mp3$ {
try_files $uri /api/preview?id=$1;
}
}
location /p2 {
proxy_pass http://127.0.0.1:34802;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "Upgrade";
}
}