代码拉取完成,页面将自动刷新
#user nobody;
worker_processes 1;
#error_log logs/error.log;
#error_log logs/error.log notice;
#error_log logs/error.log info;
#pid logs/nginx.pid;
events {
worker_connections 1024;
}
http {
include mime.types;
default_type application/octet-stream;
log_format main '$remote_addr - $remote_user [$time_local] "$request" '
'$status $body_bytes_sent "$http_referer" '
'"$http_user_agent" "$http_x_forwarded_for"';
access_log logs/access.log main;
sendfile on;
#tcp_nopush on;
#keepalive_timeout 0;
keepalive_timeout 65;
#gzip on;
server {
listen 601 default_server;
server_name _;
location / {
#root D:/Tools/code/bgpromotion/core;
root D:/Tools/code/ouser-center/ouser-center-web/src/main/resources/static;
index index.html index.htm;
}
}
server {
listen 80;
#修改成后台admin对应域名,目前可以使用下面的通用路径
server_name *.com.cn;
#charset koi8-r;
access_log logs/host.access.log main;
#http://127.0.0.1:8082/ouser-web/ 该路径根据本地启动的tomcat路径可替换
#/api/ouser-web/为代理开发环境的路径,可以谷歌开发工具查看开发环境的接口路径中找到,注意路径有api的需要再加层api路径
#location ^~ /oms-static {
# index index.html;
# alias D:\workspace\oms-static\dist;
# break;
#}
#location ^~ /back-product-service/ {
# proxy_pass http://127.0.0.1:8088/back-product-service/;
# proxy_set_header Host $host:$server_port;
# proxy_set_header X-Real-IP $remote_addr;
# proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
# break;
#}
location ^~ /back-product-static/ {
proxy_pass http://127.0.0.1:8080/back-product-static/;
proxy_set_header Host $host:$server_port;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
break;
}
#location ^~ /back-product-web/ {
# proxy_pass http://127.0.0.1:8080/product-web/;
# proxy_set_header Host $host:$server_port;
# proxy_set_header X-Real-IP $remote_addr;
# proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
# break;
#}
#location ^~ /back-merchant-web/ {
# proxy_pass http://127.0.0.1:8082/back-merchant-web/;
# proxy_set_header Host $host:$server_port;
# proxy_set_header X-Real-IP $remote_addr;
# proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
# break;
#}
#location ^~ /merchant-static/ {
# proxy_pass http://127.0.0.1:8083/merchant-static/;
# proxy_set_header Host $host:$server_port;
# proxy_set_header X-Real-IP $remote_addr;
# proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
# break;
#}
#location ^~ /oms-web/ {
# proxy_pass http://127.0.0.1:8084/oms-web/;
# proxy_set_header Host $host:$server_port;
# proxy_set_header X-Real-IP $remote_addr;
# proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
# break;
#}
#location ^~ /oms-api/ {
# proxy_pass http://127.0.0.1:8080/oms-api/;
# proxy_set_header Host $host:$server_port;
# proxy_set_header X-Real-IP $remote_addr;
# proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
# break;
#}
#
#location ^~ /oms-api-web/ {
# proxy_pass http://127.0.0.1:8080/oms-api-web/;
# proxy_set_header Host $host:$server_port;
# proxy_set_header X-Real-IP $remote_addr;
# proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
# break;
#}
#location ^~ /api/opms-web/ {
# proxy_pass http://127.0.0.1:8080/opms-web/;
# proxy_set_header Host $host:$server_port;
# break;
#}
#location ^~ /ody-channel-web/ {
# proxy_pass http://127.0.0.1:8080/ody-channel-web/;
# proxy_set_header Host $host:$server_port;
# break;
#}
#location ^~ /ouser-web/ {
# proxy_pass http://127.0.0.1:8091/ouser-service/;
# proxy_set_header Host $host:$server_port;
# break;
#}
#location ^~ /back-finance-web/ {
# proxy_pass http://127.0.0.1:8080/back-finance-web/;
# proxy_set_header Host $host:$server_port;
# break;
#}
#location ^~ /api/social-web/ {
# proxy_pass http://127.0.0.1:8092/social-web/;
# proxy_set_header Host $host:$server_port;
# break;
#}
#location ^~ /frontier-trade-web/ {
# proxy_pass http://127.0.0.1:8080/frontier-trade-web/;
# proxy_set_header Host $host:$server_port;
# break;
#}
location ^~ / {
index index.html;
#ip需要根据自己的实际代理的环境ip替换,示例中给的是2.7的开发环境ip,一般不需要改,默认只在开发环境调试
proxy_pass http://10.224.16.115/;
proxy_set_header Host $host:$server_port;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
break;
}
}
}
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。