-
Notifications
You must be signed in to change notification settings - Fork 3
/
nginx.conf
42 lines (32 loc) · 1.23 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
40
41
42
server {
listen 80;
listen [::]:80;
# 替换域名
server_name bif-udapp-js.remix-project.cn;
listen 443 ssl;
listen [::]:443 ssl;
# 替换证书
ssl_certificate /home/ubuntu/remix-bif/bif-udapp-js/bif-udapp-js.remix-project.cn_bundle.crt;
ssl_certificate_key /home/ubuntu/remix-bif/bif-udapp-js/bif-udapp-js.remix-project.cn.key;
ssl_session_timeout 5m;
ssl_protocols TLSv1.2 TLSv1.3;
ssl_ciphers ECDHE-RSA-AES128-GCM-SHA256:HIGH:!aNULL:!MD5:!RC4:!DHE;
ssl_prefer_server_ciphers on;
# 替换目录
root /home/ubuntu/remix-bif/bif-udapp-js/udapp-js;
index index.html index.htm index.nginx-debian.html;
gzip on;
gzip_vary on;
gzip_comp_level 6;
gzip_types text/plain text/css application/json application/javascript text/xml application/xml application/xml+rss text/javascript;
gzip_disable "MSIE [1-6]\.";
gzip_min_length 1024;
# 替换DNS解析服务(可选)
resolver 119.29.29.29;
location / {
try_files $uri /index.html;
}
location ~ ^/api/(.*)$ {
proxy_pass $http_ProxyAddress/$1$is_args$args;
}
}