Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

[Suggestion] Support configuring path in upstream server #792

Open
IcedSoyaBeanMilk opened this issue Apr 1, 2024 · 2 comments
Open

[Suggestion] Support configuring path in upstream server #792

IcedSoyaBeanMilk opened this issue Apr 1, 2024 · 2 comments
Labels
enhancement New feature or request

Comments

@IcedSoyaBeanMilk
Copy link

问题描述

上游服务器配置带有二级路径http://localhost:9090/dsp/,如下图:
001

直接用域名访问,无法直接访问到二级路径,只能访问到http://localhost:9090对应的页面:
002

想用域名访问,必须额外加上二级路径https://mydomain.cn/dsp:
003

nginx中可以实现用域名https://mydomain.cn直接访问到http://localhost:9090/dsp/:
004
但是safeline不行

版本号

5.2.0

复现方法

问题描述里已经写明

期望的结果

修复该问题

@Lorna0
Copy link
Collaborator

Lorna0 commented Apr 2, 2024

雷池目前不支持在上游服务器中填写路径,填写了也不会载入到代理配置中。目前展示形式确实会有能支持的误解,我们会在后续版本中加一下前端校验,做出明确提示。

不支持原因有两方面,一方面是 nginx 上游服务器路径代理的逻辑有点复杂,例如 http://192.168.10.10:88http://192.168.10.10:88/ 的效果都不一样。支持的话小白比较难理解,很容易配错,不太符合社区版的定位。

另一方面是 WAF 主要是基于已经成型了的网站进行攻击防护,所以雷池暂不打算加入太深的建站管理能力。如果想修改客户端访问网站时的根路径,可以直接修改源站上的文件路径。有其他场景需要的话也可以具体说说。

@Lorna0 Lorna0 changed the title [Bug] 上游服务器配置二级路径不生效 [建议] 支持在上游服务器中配置路径 Apr 2, 2024
@Lorna0 Lorna0 added the enhancement New feature or request label Apr 2, 2024
@Lvshujun0918
Copy link
Contributor

那建议上游服务器文本框直接拆成IP(域名)和端口两个文本框,后面再加一个http或https选择框即可。

@xbingW xbingW changed the title [建议] 支持在上游服务器中配置路径 [Suggestion] Support configuring path in upstream server Sep 19, 2024
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants