File tree Expand file tree Collapse file tree 5 files changed +32
-7
lines changed
Expand file tree Collapse file tree 5 files changed +32
-7
lines changed Original file line number Diff line number Diff line change 1+ ### citus-docker v9.2.4-2.docker (March 31, 2020) ###
2+
3+ * Add Docker Compose V3 support
4+
15### citus-docker v9.2.4.docker (March 31, 2020) ###
26
37* Bump Citus version to 9.2.4
Original file line number Diff line number Diff line change @@ -30,7 +30,8 @@ RUN echo "shared_preload_libraries='citus'" >> /usr/share/postgresql/postgresql.
3030COPY 000-configure-stats.sh 001-create-citus-extension.sql /docker-entrypoint-initdb.d/
3131
3232# add health check script
33- COPY pg_healthcheck /
33+ COPY pg_healthcheck wait-for-manager.sh /
34+ RUN chmod +x /wait-for-manager.sh
3435
3536# entry point unsets PGPASSWORD, but we need it to connect to workers
3637# https://github.com/docker-library/postgres/blob/33bccfcaddd0679f55ee1028c012d26cd196537d/12/docker-entrypoint.sh#L303
Original file line number Diff line number Diff line change 1- version : ' 2.1 '
1+ version : ' 3 '
22
33services :
44 master :
@@ -15,11 +15,18 @@ services:
1515 worker :
1616 image : ' citusdata/citus:9.2.4'
1717 labels : ['com.citusdata.role=Worker']
18- depends_on : { manager: { condition: service_healthy } }
18+ depends_on : [ manager ]
1919 environment : *AUTH
20+ command : " /wait-for-manager.sh"
21+ volumes :
22+ - healthcheck-volume:/healthcheck
2023 manager :
2124 container_name : " ${COMPOSE_PROJECT_NAME:-citus}_manager"
22- image : ' citusdata/membership-manager:0.2.1'
23- volumes : ['/var/run/docker.sock:/var/run/docker.sock']
24- depends_on : { master: { condition: service_healthy } }
25+ image : ' citusdata/membership-manager:0.3.0'
26+ volumes :
27+ - /var/run/docker.sock:/var/run/docker.sock
28+ - healthcheck-volume:/healthcheck
29+ depends_on : [ master ]
2530 environment : *AUTH
31+ volumes :
32+ healthcheck-volume :
Original file line number Diff line number Diff line change @@ -19,7 +19,7 @@ services:
1919 environment : *AUTH
2020 manager :
2121 container_name : " ${COMPOSE_PROJECT_NAME:-citus}_manager"
22- image : ' citusdata/membership-manager:0.2.1 '
22+ image : ' citusdata/membership-manager:latest '
2323 volumes : ['/var/run/docker.sock:/var/run/docker.sock']
2424 depends_on : { master: { condition: service_healthy } }
2525 environment : *AUTH
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+ # wait-for-manager.sh
3+
4+ set -e
5+
6+ until test -f /healthcheck/manager-ready ; do
7+ >&2 echo " Manager is not ready - sleeping"
8+ sleep 1
9+ done
10+
11+ >&2 echo " Manager is up - starting worker"
12+
13+ exec gosu postgres " /docker-entrypoint.sh" " postgres"
You can’t perform that action at this time.
0 commit comments