我的哨兵连接到9000端口有问题。
在文件中,我需要启动odoo(dev9-local)并使用postgres(dev9-db)中的数据库启动哨兵,我创建了8个服务,但其中一个不起作用,哨兵服务具有端口9000,但是当我端口9000中的open chrome无法加载哨兵,我检查了很多次代码,但没有发现错误,odoo服务正常工作,但是哨兵无法正常工作,谢谢您的帮助。
我可以在postgres中使用数据库运行odoo,并使用其自己的数据库运行哨兵,但是当两个服务共享同一数据库时,它就无法工作。
version: '3'
services:
sentry:
container_name: sentry
image: sentry
environment:
- SENTRY_POSTGRES_HOST=dev9-db
- SENTRY_POSTGRES_PORT=5432
- SENTRY_DB_USER=odoo
- SENTRY_DB_PASSWORD=1111
- SENTRY_REDIS_HOST=redis
- SENTRY_REDIS_PORT=6379
- SENTRY_SECRET_KEY=kvxbpdgnmzk5r4h=jz+p8sbkoep04b+wjl+ctlt!hsw-_uz5-^
ports:
- '9000:9000'
depends_on:
- dev9-db
- redis
stdin_open: true
cron:
container_name: sentry-cron
image: sentry
command: run cron
environment:
- SENTRY_POSTGRES_HOST=dev9-db
- SENTRY_POSTGRES_PORT=5432
- SENTRY_DB_USER=odoo
- SENTRY_DB_PASSWORD=1111
- SENTRY_REDIS_HOST=redis
- SENTRY_REDIS_PORT=6379
- SENTRY_SECRET_KEY=kvxbpdgnmzk5r4h=jz+p8sbkoep04b+wjl+ctlt!hsw-_uz5-^
depends_on:
- dev9-db
- redis
worker:
container_name: sentry-worker
image: sentry
command: run worker
environment:
- SENTRY_POSTGRES_HOST=dev9-db
- SENTRY_POSTGRES_PORT=5432
- SENTRY_DB_USER=odoo
- SENTRY_DB_PASSWORD=1111
- SENTRY_REDIS_HOST=redis
- SENTRY_REDIS_PORT=6379
- SENTRY_SECRET_KEY=kvxbpdgnmzk5r4h=jz+p8sbkoep04b+wjl+ctlt!hsw-_uz5-^
depends_on:
- dev9-db
- redis
redis:
container_name: sentry-redis
image: redis
volumes:
- redis-data:/data
ports:
- '6379:6379'
dev9-local:
image: fslibre/odoo:12.0
tty: True
networks:
- dev9-network
environment:
- USER=odoo
- PASSWORD=1111
- WDB_NO_BROWSER_AUTO_OPEN=True
- WDB_SOCKET_SERVER=dev9-depurador
- WDB_WEB_PORT=1988
- WDB_WEB_SERVER=localhost
depends_on:
- dev9-db
- dev9-depurador
ports:
- "8088:8069"
volumes:
- /home/mason/Documentos/odoo12/extra-addons:/mnt/extra-addons/
- /home/mason/Documentos/odoo12/etc/odoo/:/etc/odoo/
- pg-data:/var/lib/postgresql/data
command: -- --db-filter=.*
dev9-db:
image: postgres:10.0
environment:
POSTGRES_USER: odoo
POSTGRES_PASSWORD: 1111
networks:
dev9-network:
aliases:
- db
ports:
- '5432:5432'
res9-pgadmin4:
image: fenglc/pgadmin4:slim
environment:
- DEFAULT_USER=admin
- DEFAULT_PASSWORD=1111
ports:
- "5058:5050"
networks:
- dev9-network
dev9-depurador:
image: fabricadesoftwarelibre/libregob-depurador:18.1
networks:
dev9-network:
aliases:
- depurador
ports:
- "1988:1984"
volumes:
redis-data:
pg-data:
networks:
dev9-network:
当我输入localhost:8088时,Odoo可以正常工作,但是当我输入localhost:9000哨兵未加载,ERR_CONNECTION_REFUSED时,所有内容都可以在控制台上正确运行,这是一个代码错误。