29 lines
893 B
Plaintext
29 lines
893 B
Plaintext
limit_conn_zone $server_name zone=archive_parallel:1m;
|
|
server {
|
|
listen 80;
|
|
server_name _;
|
|
root /usr/share/nginx/html;
|
|
index index.html;
|
|
charset utf-8;
|
|
client_max_body_size 17m;
|
|
location /api/ {
|
|
limit_conn archive_parallel 4;
|
|
resolver 127.0.0.11 valid=10s ipv6=off;
|
|
set $backup_host backup;
|
|
proxy_pass http://$backup_host:8080;
|
|
proxy_set_header Host $host;
|
|
proxy_set_header X-Real-IP $http_x_real_ip;
|
|
proxy_read_timeout 120s;
|
|
proxy_send_timeout 120s;
|
|
add_header X-Robots-Tag noindex always;
|
|
}
|
|
location / {
|
|
try_files $uri $uri/ =404;
|
|
add_header Cache-Control "no-cache";
|
|
add_header X-Content-Type-Options nosniff;
|
|
}
|
|
location ~ /\. { deny all; }
|
|
gzip on;
|
|
gzip_types text/plain application/javascript application/json;
|
|
}
|