-
Notifications
You must be signed in to change notification settings - Fork 0
/
nginx.conf
36 lines (31 loc) · 951 Bytes
/
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
map $sent_http_content_type $expires {
default off;
text/html epoch;
image/svg+xml 180d;
image/png 180d;
image/jpeg 180d;
image/webp 180d;
image/x-icon 180d;
text/css 365d;
application/javascript 365d;
application/json epoch;
}
server {
listen 80;
server_name localhost;
access_log off;
error_log off;
server_tokens off;
root /usr/share/nginx/html;
index index.html index.htm;
location ~ /index.html {
add_header Cache-Control 'no-store, no-cache, must-revalidate, proxy-revalidate, max-age=0';
expires $expires;
include /etc/nginx/security-headers.conf;
}
location / {
expires $expires;
try_files $uri $uri/ /index.html;
include /etc/nginx/security-headers.conf;
}
}