| 123456789101112131415161718192021222324252627282930313233343536 |
- # nginx.conf - adminui 总后台(fs-nginx-admin)
- # 与 vue.config.js 一致:全部 /prod-api/* → fs-admin:8003
- worker_processes 5;
- events {
- worker_connections 1024;
- }
- http {
- include mime.types;
- default_type application/octet-stream;
- client_max_body_size 200m;
- sendfile on;
- keepalive_timeout 65;
- server {
- listen 80;
- server_name localhost;
- root /usr/share/nginx/html;
- index index.html;
- location / {
- try_files $uri $uri/ /index.html;
- }
- # 默认全部 API → fs-admin(内网 192.168.58.159:8003)
- location /prod-api/ {
- proxy_pass http://192.168.58.159:8003/;
- 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_set_header X-Forwarded-Proto $scheme;
- }
- }
- }
|