diff --git a/overrides/compose.postgres.yaml b/overrides/compose.postgres.yaml index 433ca71a..2d8e7876 100644 --- a/overrides/compose.postgres.yaml +++ b/overrides/compose.postgres.yaml @@ -2,13 +2,29 @@ services: configurator: environment: DB_HOST: db - DB_PORT: 5432 + DB_PORT: "5432" + DB_TYPE: postgres + command: + - > + ls -1 apps > sites/apps.txt; + bench set-config -g db_type postgres; + bench set-config -g db_host $$DB_HOST; + bench set-config -gp db_port $$DB_PORT; + bench set-config -g redis_cache "redis://$$REDIS_CACHE"; + bench set-config -g redis_queue "redis://$$REDIS_QUEUE"; + bench set-config -g redis_socketio "redis://$$REDIS_QUEUE"; + bench set-config -gp socketio_port $$SOCKETIO_PORT; + bench set-config -g chromium_path /usr/bin/chromium-headless-shell; depends_on: - - db + db: + condition: service_healthy db: - image: postgres:13.5 - command: [] + image: postgres:15-alpine + healthcheck: + test: ["CMD-SHELL", "pg_isready -U postgres"] + interval: 5s + retries: 5 environment: POSTGRES_PASSWORD: ${DB_PASSWORD:?No db password set} volumes: