修改nginx.conf
upstream test-svr {
server 127.0.0.1:81;
}
server {
listen 80;
server_name test-localhost.com;
location / {
proxy_pass http://jnpm-svr;
proxy_http_version 1.1;
proxy_set_header Connection $http_connection;
}
}
添加 /etc/hosts
127.0.0.1 test-localhost.com
此时curl test-localhost.com
就会转发到81端口了
相关文档
暂无
随便看看
畅言模块加载中