-
Notifications
You must be signed in to change notification settings - Fork 0
/
default.conf
39 lines (31 loc) · 1.39 KB
/
default.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
server {
# users are not allowed to listen on privileged ports
listen 8080;
server_name localhost;
absolute_redirect off; # disable absolute redirects since this nginx will run behind the kubernetes ingress load balancer handling https for us. With this enabled, the redirects e.g. from https://kb.vshn.ch/app-catalog will be wrongly generated to http://kb.vshn.ch:8080/app-catalog/ because nginx runs http on port 8080 behind the ingress handling https at default port 443.
large_client_header_buffers 4 16k; # oauth proxies can exceed the default 8k request size due to excessive cookie data
include /etc/nginx/antora/*.conf;
# enable compression for all html, css and javascript
gzip on;
gzip_types text/html text/css text/javascript;
# 404 error page
error_page 404 =404 /404.html;
location / {
root /usr/share/nginx/html;
index index.html index.htm;
}
# Redirect all searches to the Node.js app
# in the other container of the same pod.
location /search {
proxy_pass http://localhost:3000;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection 'upgrade';
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;
}
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root /usr/share/nginx/html;
}
}