您的位置: 首页 > IT文章 > nginx一个简单的反向代理设置 nginx一个简单的反向代理设置 分类: IT文章 • 2022-08-15 16:41:39 location /aaaaa/ { proxy_pass http://localhost:8080/aaaaa/; } 经过配置,现在访问 http://localhost/aaaaa/ 就会转到 http://localhost:8080/aaaaa/ 注意:正斜杠 和 分号 不能少 例子:在nginx中配置代理,就可以把服务器的8080端口关闭,通过代理内部访问 参考