本帖最后由 堡塔运维香菜卷 于 2023-3-25 11:39 编辑
如果使用了域名,或者不同端口来反向代理了宝塔面板,在通过面板访问 phpmyadmin 后会出现后面跟着一个不对的端口的情况,应该把面板里 class/panelHttpProxy.py 文件中的 45 行:
- if headers[h].find('127.0.0.1') != -1:
- headers[h] = re.sub(r"https?://127.0.0.1(:\d+)?/",request.url_root,headers[h])
复制代码 改为
- if headers[h].find('127.0.0.1') != -1 or headers[h].find('phpmyadmin') != -1:
- headers[h] = re.sub(r"https?://[^/]+/",request.url_root,headers[h])
复制代码
|
|