From 9c3bdb5f09f607f3651686e22c4f19ea49782819 Mon Sep 17 00:00:00 2001 From: Nino Date: Mon, 12 Aug 2024 09:54:09 +0200 Subject: [PATCH] celery entrypoint --- app/deploy/docker-entrypoint.celery.sh | 6 ++++++ docker-compose.local.yml | 2 ++ 2 files changed, 8 insertions(+) create mode 100755 app/deploy/docker-entrypoint.celery.sh diff --git a/app/deploy/docker-entrypoint.celery.sh b/app/deploy/docker-entrypoint.celery.sh new file mode 100755 index 00000000..7be07b30 --- /dev/null +++ b/app/deploy/docker-entrypoint.celery.sh @@ -0,0 +1,6 @@ +#!/usr/bin/env bash +set -u # crash on missing env variables +set -e # stop on any error +set -x + +exec "$@" diff --git a/docker-compose.local.yml b/docker-compose.local.yml index 55703bd3..a6b4634d 100644 --- a/docker-compose.local.yml +++ b/docker-compose.local.yml @@ -47,6 +47,7 @@ services: image: ${REGISTRY:-127.0.0.1:5001}/${REPOSITORY:-salmagundi/top-backend}:${VERSION:-latest} container_name: top_celery_worker hostname: top_celery_worker + entrypoint: /app/deploy/docker-entrypoint.celery.sh command: bash -c "/app/wait-for.sh http://api:8000 -- /app/celery.sh" depends_on: - api @@ -62,6 +63,7 @@ services: image: ${REGISTRY:-127.0.0.1:5001}/${REPOSITORY:-salmagundi/top-backend}:${VERSION:-latest} container_name: top_celery_beat hostname: top_celery_beat + entrypoint: /app/deploy/docker-entrypoint.celery.sh command: bash -c "/app/wait-for.sh http://api:8000 -- /app/celery-beat.sh" # command: bash -c "/app/celery-beat.sh" depends_on: