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
| server { listen 80; server_name xxx.com; root html; index index.html index.htm;
location /favicon.ico { root /usr/share/nginx/html/; }
location /api { proxy_redirect off; proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_pass http://127.0.0.1:8080; }
location / { root /dist; index index.html index.htm; try_files $uri $uri/ @rewrites; }
location @rewrites{ rewrite ^(.+)$ /index.html last; } location ~* ^/(node|info|search)/ { proxy_pass http://localhost:8080; } }
location ~* ^/(sys|app|api|oss|login|getInfo|logout) { proxy_redirect off; proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_cache_valid 200 60m; proxy_cache_min_uses 2; proxy_cache_methods GET; proxy_pass http://127.0.0.1:9090; }
location ~^/ddchain/ { proxy_redirect off; proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_connect_timeout 600s; proxy_send_timeout 600s; proxy_read_timeout 600s; proxy_pass http://127.0.0.1:8089; rewrite "^/ddchain(.*)$" $1 break; }
|