forked from swagger-api/swagger-editor
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathnginx.conf
39 lines (32 loc) · 1.06 KB
/
nginx.conf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
gzip on;
gzip_static on;
gzip_disable "msie6";
gzip_vary on;
gzip_types text/plain text/css application/javascript;
add_header X-Frame-Options deny;
server_tokens off; # Hide Nginx version
upstream apifant_valigator {
server $VALIGATOR_HOST:$VALIGATOR_PORT;
}
server {
listen $PORT;
server_name 0.0.0.0;
location ~* /(valigator/.*) {
proxy_pass $VALIGATOR_SCHEME://apifant_valigator/$1$is_args$args;
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_read_timeout 300; # Timeout für das Lesen von Backend
proxy_connect_timeout 300; # Timeout für die Verbindung zum Backend
proxy_send_timeout 300; # Timeout für das Senden an den Client
}
location $BASE_URL {
absolute_redirect off;
alias /usr/share/nginx/html/;
index index.html index.htm;
location ~* \.(?:json|yml|yaml)$ {
#SWAGGER_ROOT
expires -1;
}
}
}