oncall
oncall copied to clipboard
Getting this project up with docker-compose "Waited too long for DB to come up. Bailing."
Just updated my docker-compose.yaml
to look like this:
version: '3'
services:
oncall-web:
build: .
ports:
- "8080:8080"
environment:
- DOCKER_DB_BOOTSTRAP=1
depends_on:
- oncall-mysql
oncall-mysql:
image: mysql:5.7
environment:
- MYSQL_ROOT_PASSWORD=1234
But it can't connect to the db? How do I fix this?
oncall-web_1 | Checking MySQL liveness on mysql...
oncall-web_1 | DB not up yet. Waiting a few seconds..
oncall-web_1 | DB not up yet. Waiting a few seconds..
oncall-web_1 | DB not up yet. Waiting a few seconds..
oncall-web_1 | DB not up yet. Waiting a few seconds..
oncall-web_1 | DB not up yet. Waiting a few seconds..
oncall-web_1 | DB not up yet. Waiting a few seconds..
oncall-web_1 | DB not up yet. Waiting a few seconds..
oncall-web_1 | DB not up yet. Waiting a few seconds..
oncall-web_1 | DB not up yet. Waiting a few seconds..
oncall-web_1 | DB not up yet. Waiting a few seconds..
oncall-web_1 | DB not up yet. Waiting a few seconds..
oncall-web_1 | DB not up yet. Waiting a few seconds..
oncall-web_1 | DB not up yet. Waiting a few seconds..
oncall-web_1 | DB not up yet. Waiting a few seconds..
oncall-web_1 | DB not up yet. Waiting a few seconds..
oncall-web_1 | DB not up yet. Waiting a few seconds..
oncall-web_1 | DB not up yet. Waiting a few seconds..
oncall-web_1 | DB not up yet. Waiting a few seconds..
oncall-web_1 | DB not up yet. Waiting a few seconds..
oncall-web_1 | DB not up yet. Waiting a few seconds..
oncall-web_1 | DB not up yet. Waiting a few seconds..
oncall-web_1 | Waited too long for DB to come up. Bailing.
oncall_oncall-web_1 exited with code 1
Missing this part in the oncall-web
section?
volumes:
- ./configs/config.docker.yaml:/home/oncall/config/config.yaml
Checking MySQL liveness on mysql...
OnCall is looking for mysql server at host name mysql
in your docker-compose.yaml
it's set up as oncall-mysql
.