直接粘贴到配置文件即可
location ~* \.(js|css|png|jpg|jpeg|gif|ico|eot|otf|ttf|woff|woff2)$ {
proxy_pass 代理的地址;
add_header Access-Control-Allow-Origin *;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
expires 1d;
}
location = /favicon.ico {
log_not_found off;
}
location /oa/ {
proxy_pass http://192.168.189.164:1340/;
}
location /static/ {
proxy_pass http://192.168.189.164:1340/static//;
}