2025-04-27 19:09:32 +02:00
|
|
|
server {
|
|
|
|
|
listen 8080;
|
|
|
|
|
server_name localhost;
|
2025-05-05 00:47:36 +02:00
|
|
|
root /tmp/site;
|
|
|
|
|
|
|
|
|
|
resolver kube-dns.kube-system.svc.cluster.local valid=10s;
|
2025-04-27 19:09:32 +02:00
|
|
|
|
|
|
|
|
gzip on;
|
|
|
|
|
gzip_comp_level 9;
|
|
|
|
|
gzip_types
|
|
|
|
|
text/html
|
|
|
|
|
text/plain
|
|
|
|
|
text/css
|
|
|
|
|
text/js
|
|
|
|
|
text/xml
|
|
|
|
|
text/javascript
|
|
|
|
|
application/javascript
|
|
|
|
|
application/json
|
|
|
|
|
application/xml
|
|
|
|
|
application/rss+xml
|
|
|
|
|
image/svg+xml;
|
|
|
|
|
|
2025-05-05 19:56:43 +02:00
|
|
|
location ^~ /config/dav {
|
|
|
|
|
proxy_pass http://http.sftpgo.svc.cluster.local:8080/config/dav;
|
2025-05-05 00:47:36 +02:00
|
|
|
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 $scheme;
|
|
|
|
|
proxy_set_header X-Forwarded-Host $host;
|
|
|
|
|
proxy_set_header X-Forwarded-Port $server_port;
|
|
|
|
|
}
|
2025-04-27 19:09:32 +02:00
|
|
|
|
|
|
|
|
location / {
|
|
|
|
|
index index.html index.htm;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
location ~* ^/([^/]+) {
|
|
|
|
|
index index.html index.htm;
|
|
|
|
|
error_page 404 = @error;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
error_page 404 /404.html;
|
|
|
|
|
location @error {
|
|
|
|
|
try_files /$1/404.html /404.html =404;
|
|
|
|
|
}
|
|
|
|
|
}
|