-
-
Notifications
You must be signed in to change notification settings - Fork 22
/
deployment-nginx.conf
65 lines (53 loc) · 1.57 KB
/
deployment-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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
user www-data;
worker_processes auto;
pid /run/nginx.pid;
include /etc/nginx/modules-enabled/*.conf;
events {
worker_connections 768;
}
http {
sendfile on;
tcp_nopush on;
tcp_nodelay on;
keepalive_timeout 65;
types_hash_max_size 2048;
server_tokens off;
include /etc/nginx/mime.types;
default_type application/octet-stream;
ssl_protocols TLSv1 TLSv1.2 TLSv1.3; # Dropping SSLv3, ref: POODLE
ssl_prefer_server_ciphers on;
ssl_session_cache shared:SSL:10m;
ssl_session_timeout 10m;
access_log /var/log/nginx/access.log;
error_log /var/log/nginx/error.log;
include /etc/nginx/conf.d/*.conf;
include /etc/nginx/sites-enabled/*;
add_header Content-Security-Policy "default-src 'self' *.thebcms.com 'unsafe-inline' blob: data:";
add_header Strict-Transport-Security "max-age=31536000; includeSubDomains" always;
add_header Referrer-Policy "no-referrer";
server {
listen @port default_server;
listen [::]:@port default_server;
server_name @server_name;
@ssl
client_max_body_size 105G;
location /api/v4/socket {
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
proxy_pass http://@project_name:8080/api/v4/socket;
}
location /__plugin {
proxy_read_timeout 60;
proxy_connect_timeout 60;
proxy_send_timeout 60;
proxy_pass http://@project_name:8080/__plugin;
}
location / {
proxy_read_timeout 60;
proxy_connect_timeout 60;
proxy_send_timeout 60;
proxy_pass http://@project_name:8080;
}
}
}