配置文件nginx.conf
server{#開啓一個服務器
listen 8000#監聽端口號
server_name localhost;#本地直接填localhost就行
location ~ \.do$ {#配置代理那些請求路徑,符合規則的就進入代理
proxy_pass http://xxx.xxx.xxx.xxx #配置代理服務地址
}
add_header "Access-Control-Allow-Origin" "*" #配置跨域
}