-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathnginxprod.conf
69 lines (57 loc) · 1.99 KB
/
nginxprod.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
66
67
68
69
events {
worker_connections 1024;
}
http {
include /etc/nginx/mime.types;
default_type application/octet-stream;
#access_log /dev/null;
#error_log /dev/null;
access_log /var/log/nginx/access.log;
error_log /var/log/nginx/error.log warn;
client_max_body_size 100m;
# Enable Gzip Compression
#gzip on;
#gzip_disable "msie6"; # Disable for old browsers
# Specify gzip compression level (1-9, where 9 is the highest compression)
#gzip_comp_level 6;
# Specify MIME types to compress
#gzip_types text/plain text/css application/json application/javascript text/xml application/xml application/xml+rss text/javascript;
# Enable compression both for HTTP/1.0 and HTTP/1.1.
#gzip_proxied any;
# Enable for all proxies
# gzip_vary on;
# HTTPS Server for development
server {
listen 80;
listen 443 ssl http2;
server_name dev.fbctreasurevalley.net;
ssl_certificate /etc/ssl/cert.pem;
ssl_certificate_key /etc/ssl/key.pem;
# SSL settings optimized for development
ssl_session_cache shared:SSL:1m;
ssl_session_timeout 10m;
ssl_ciphers HIGH:!aNULL:!MD5;
ssl_prefer_server_ciphers on;
location /api {
proxy_read_timeout 3000s;
proxy_pass http://oldtest:8080;
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;
}
#location / {
# root /usr/share/nginx/html;
# try_files $uri $uri/ /index.html;
#}
location / {
proxy_pass http://newtest:5173;
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;
}
}
}