Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

[BUG]使用NGINX进行二级域点跳转会出现js路径不正常 #304

Closed
Arrding opened this issue Apr 28, 2024 · 2 comments
Closed

[BUG]使用NGINX进行二级域点跳转会出现js路径不正常 #304

Arrding opened this issue Apr 28, 2024 · 2 comments
Assignees

Comments

@Arrding
Copy link

Arrding commented Apr 28, 2024

联系方式

No response

MaxKB 版本

版本号:v1.0.4

问题描述

需求:在nginx上设置二级域名LLM,跳转到内网IP,经测试发现,嵌入第三方的url在这种场景下,不会加上LLM,导致js路径报错。

重现步骤

1
2
3
4
5
6
7
8

期待的正确结果

能正确识别这种转发并加上目录

相关日志输出

No response

附加信息

No response

@shaohuzhang1
Copy link
Collaborator

目前maxkb无法解决这一个问题,因为maxkb 的ui再打包的时候指定了BASE_PATH=/ui/ 如果需要使用nginx的二级路径负载均衡 则需要修改ui/env/.env 修改BASE_PATH
image
然后使用npm run build 使用nginx代理前后端

@shaohuzhang1
Copy link
Collaborator

因为除了index.html的src 其他js里面的src也是通过base_path决定的 经过尝试只修改index.html无法达到预期效果。
只能重新打包才可以做到,所以maxkb不能支持你这个需求

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants