From caa94f4d6912492a97d021593f76519bb1d82bff Mon Sep 17 00:00:00 2001 From: 3wc <3wc.git@doesthisthing.work> Date: Wed, 23 Sep 2020 14:21:22 +0200 Subject: [PATCH] Fix DB connection, add healthcheck --- .envrc.sample | 4 ++-- README.md | 5 +++-- compose.yml | 19 +++++++++---------- 3 files changed, 14 insertions(+), 14 deletions(-) diff --git a/.envrc.sample b/.envrc.sample index 2fae517..4495759 100644 --- a/.envrc.sample +++ b/.envrc.sample @@ -15,8 +15,8 @@ export SELFOSS_PASSWORD= # The recommended /password hash script currently seems broken; use this instead: # http://www.passwordtool.hu/php5-password-hash-generator -# Options are ERROR, WARNING, INFO, DEBU -export SELFOSS_LOGGER_LEVEL=DEBUG +# Options are EMERGENCY, ALERT, CRITICAL, ERROR, WARNING, NOTICE, INFO, DEBUG, None +export SELFOSS_LOGGER_LEVEL=ERROR export ENTRYPOINT_CONF_VERSION=v7 export DB_PASSWORD_VERSION=v1 diff --git a/README.md b/README.md index e1e210c..f53f056 100644 --- a/README.md +++ b/README.md @@ -11,8 +11,9 @@ production use. 4. Edit `.envrc` - be sure to change `$DOMAIN` to something that resolves to your Docker swarm box 5. `direnv allow` (or `. .envrc`) -6. `abra deploy` -8. Open the configured domain in your browser to finish set-up +6. `abra secret_generate db_password v1` +7. `abra deploy` +9. Open the configured domain in your browser to finish set-up [selfoss]: https://www.selfoss.aditu.de/ [abra]: https://git.autonomic.zone/autonomic-cooperative/abra diff --git a/compose.yml b/compose.yml index 23953a9..3e85fe3 100644 --- a/compose.yml +++ b/compose.yml @@ -41,9 +41,9 @@ services: #- SELFOSS_PASSWORD_FILE=/run/secrets/selfoss_password - SELFOSS_DB_TYPE - SELFOSS_LOGGER_LEVEL - - SELFOSS_DB_HOST="postgres" - - SELFOSS_DB_NAME="selfoss" - - SELFOSS_DB_USERNAME="selfoss" + - SELFOSS_DB_HOST=postgres + - SELFOSS_DB_NAME=selfoss + - SELFOSS_DB_USERNAME=selfoss - SELFOSS_DB_PASSWORD_FILE=/run/secrets/db_password secrets: - db_password @@ -59,13 +59,12 @@ services: - internal depends_on: - postgres - # TODO 3wc: not working currently, complains about YAML syntax error - #healthcheck: - # test: ["CMD", "wget", "-f" "http://localhost:8888"] - # interval: 30s - # timeout: 10s - # retries: 10 - # start_period: 1m + healthcheck: + test: ["CMD", "wget", "-qO", "-", "http://localhost:8888"] + interval: 30s + timeout: 10s + retries: 10 + start_period: 1m networks: proxy: