后端的接口 也是/api/xxx 开头的吗 server { listen 8065; proxy_read_timeout 300; proxy_connect_timeout 300; proxy_send_timeout 300; root /home/web/bigscreen/dist/; location / { # client_max_body_size 20M; # body 请求体 413错 # client_max_body_size 20M; index index.html; try_files $uri $uri/ /index.html; if ($uri ~* \.(html)$) { add_header Cache-Control "private, no-store, no-cache, must-revalidate, proxy-revalidate"; } } location /api/ { proxy_set_header Host $http_host; proxy_set_header X-Real-Ip $remote_addr; proxy_set_header REMOTE-HOST $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_pass http://xxxx9:8989/; } } 给你一个我经常使用的配置
后端的接口 也是/api/xxx 开头的吗
给你一个我经常使用的配置