From 28c61213f261dfb66dd340df6da9c65603a8b17f Mon Sep 17 00:00:00 2001 From: Essem Date: Tue, 6 Sep 2022 16:00:02 -0500 Subject: [PATCH] Some docker-compose fixes --- docker-compose.yml | 15 ++++++++++++--- docs/docker.md | 4 ++-- 2 files changed, 14 insertions(+), 5 deletions(-) diff --git a/docker-compose.yml b/docker-compose.yml index a43ce3b..f85fd07 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -10,17 +10,20 @@ services: - ./logs:/home/esmBot/.internal/logs - ./bot-help:/home/esmBot/help - ./bot-temp:/home/esmBot/temp - - ./config/servers.json:/home/esmBot/.internal/config/servers.json + - ./config:/home/esmBot/.internal/config env_file: - .env environment: OUTPUT: /home/esmBot/help/help.md TEMPDIR: /home/esmBot/temp + user: root links: - lavalink depends_on: - - lavalink - - postgres + lavalink: + condition: service_healthy + postgres: + condition: service_started networks: esmbot: @@ -33,6 +36,12 @@ services: volumes: - ./application.yml:/opt/Lavalink/application.yml - ./assets:/opt/Lavalink/assets + healthcheck: + test: "curl -H \"Authorization: $$(cat /opt/Lavalink/application.yml | grep password: | sed 's/^ *password: //g' | tr -d '\"')\" -f http://localhost:2333/version" + interval: 10s + timeout: 10s + retries: 5 + start_period: 10s networks: esmbot: ipv4_address: 172.20.0.3 diff --git a/docs/docker.md b/docs/docker.md index f1018c8..217c701 100644 --- a/docs/docker.md +++ b/docs/docker.md @@ -8,11 +8,11 @@ cd ~ git clone --recurse-submodules https://github.com/esmBot/esmBot cd esmBot ``` -Modify the `.env` file as described in step 5 of the manual setup. Make sure to change the `DB` option to this, however: +Modify the `.env` file as described in step 7 of the manual setup. Make sure to change the `DB` option to this, however: ``` DB=postgresql://esmbot:verycoolpass100@postgres:5432/esmbot ``` -You should then modify the `servers.json` file to change the IP addresses of the servers to match the Docker containers. Example: +You should then modify the `config/servers.json` file to change the IP addresses of the servers to match the Docker containers. Example: ```json { "lava": [