-
如题 |
Beta Was this translation helpful? Give feedback.
Answered by
eryajf
Jun 21, 2022
Replies: 1 comment
-
如果你并非在localhost进行部署,而是通过服务器IP或者域名访问,那么需要 因为demo环境就是这样拉起的,我这里直接将demo环境的拉起脚本放在这里,大家可以根据自己的情况进行修改: $ cat start-docker-compose.sh
#!/bin/bash
cd /data/docker-compose/go-ldap-admin-demo
docker-compose up -d
# 修改前端调用后端的地址
docker exec -it go-ldap-admin-ui sh -c "sed -i 's@localhost:[email protected]@g' static/js/app.*.js"
docker exec -it go-ldap-admin-ui sh -c "nginx -s reload"
$ docker exec -it go-ldap-admin-ui sh -c "sed -i 's@localhost:[email protected]:8888@g' static/js/app.*.js" |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
lql95
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
如果你并非在localhost进行部署,而是通过服务器IP或者域名访问,那么需要
修改前端代码中连接后端的地址
。因为demo环境就是这样拉起的,我这里直接将demo环境的拉起脚本放在这里,大家可以根据自己的情况进行修改:
注意:
如果你的IP是192.168.0.1
,那么你的替换命令应该如下: