测试弹窗

Nginx 加上路径的反向代理

情况:

用户请求 example.com

为站点的静态页面

用户请求 example.com/api

为后端接口,后端需要收到包含 /api 路径请求

后端暴露在本地8360端口中

nginx配置文件添加如下

location ~/api/
{
    proxy_pass http://127.0.0.1:8360;
}

文章不错?点个赞呗

0

毛毛虫
毛毛虫

我想回到从前,但现实没有给我机会

文章: 7159

留下评论

您的邮箱地址不会被公开。 必填项已用 * 标注