From 7430740351e47fa75ea6389c72fecb7dfad4d637 Mon Sep 17 00:00:00 2001 From: PM Extra Date: Tue, 2 Nov 2021 19:25:08 +0800 Subject: [PATCH] Improve health check for docker-compose. --- docker-compose-non-dev.yml | 6 ++++++ docker-compose.yml | 8 ++++++++ 2 files changed, 14 insertions(+) diff --git a/docker-compose-non-dev.yml b/docker-compose-non-dev.yml index 84bbc3b7a8e5a..8990c374fb261 100644 --- a/docker-compose-non-dev.yml +++ b/docker-compose-non-dev.yml @@ -60,6 +60,8 @@ services: depends_on: *superset-depends-on user: "root" volumes: *superset-volumes + healthcheck: + disable: true superset-worker: image: *superset-image @@ -70,6 +72,8 @@ services: depends_on: *superset-depends-on user: "root" volumes: *superset-volumes + healthcheck: + test: ["CMD-SHELL", "celery inspect ping -A superset.tasks.celery_app:app -d celery@$$HOSTNAME"] superset-worker-beat: image: *superset-image @@ -80,6 +84,8 @@ services: depends_on: *superset-depends-on user: "root" volumes: *superset-volumes + healthcheck: + disable: true volumes: superset_home: diff --git a/docker-compose.yml b/docker-compose.yml index 3131d2384a761..bc98a1f59878b 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -100,6 +100,8 @@ services: volumes: *superset-volumes environment: CYPRESS_CONFIG: "${CYPRESS_CONFIG}" + healthcheck: + disable: true superset-node: image: node:16 @@ -118,6 +120,8 @@ services: depends_on: *superset-depends-on user: *superset-user volumes: *superset-volumes + healthcheck: + test: ["CMD-SHELL", "celery inspect ping -A superset.tasks.celery_app:app -d celery@$$HOSTNAME"] # Bump memory limit if processing selenium / thumbails on superset-worker # mem_limit: 2038m # mem_reservation: 128M @@ -131,6 +135,8 @@ services: depends_on: *superset-depends-on user: *superset-user volumes: *superset-volumes + healthcheck: + disable: true superset-tests-worker: image: *superset-image @@ -147,6 +153,8 @@ services: depends_on: *superset-depends-on user: *superset-user volumes: *superset-volumes + healthcheck: + test: ["CMD-SHELL", "celery inspect ping -A superset.tasks.celery_app:app -d celery@$$HOSTNAME"] volumes: superset_home: