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

容器运行不能查询数据库 #291

Open
ltgentoo opened this issue Sep 7, 2020 · 1 comment
Open

容器运行不能查询数据库 #291

ltgentoo opened this issue Sep 7, 2020 · 1 comment

Comments

@ltgentoo
Copy link

ltgentoo commented Sep 7, 2020

用容器运行,db管理-》mysql-》数据查询,一直pending
QQ截图20200907163240
QQ截图20200907163259
不使用容器运行则没有这个问题,ops_web镜像是使用docker目录的build.sh构建的

@ltgentoo
Copy link
Author

ltgentoo commented Sep 14, 2020

找到问题了
OpsManage/init.py文件中
from celery import app as celery_app
应该为
from .celery import app as celery_app
之前的代码中celery配置参数不生效,连接的是默认的rabbitmq://guest:guest@127.0.0.1,如果恰好应用和rabbitmq正好在同一台主机上,就没有问题,不然就有问题了

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

No branches or pull requests

1 participant