From f51eb4de02258e16b1eedfd44094f012a398e91b Mon Sep 17 00:00:00 2001 From: Jan Kiesewetter <3628035+t3easy@users.noreply.github.com> Date: Thu, 16 Aug 2018 12:40:41 +0200 Subject: [PATCH] Set restart option with .env (#87) For better testing, the restart option of the containers is moved to .env --- .env | 1 + docker-compose.yml | 16 ++++++++-------- 2 files changed, 9 insertions(+), 8 deletions(-) diff --git a/.env b/.env index e05dd84..5d7c3f1 100644 --- a/.env +++ b/.env @@ -2,3 +2,4 @@ # example: VERSION=-2.1.0-13 IMAGE_REPO=zammad/zammad-docker-compose VERSION= +RESTART=always \ No newline at end of file diff --git a/docker-compose.yml b/docker-compose.yml index 3d2e1c8..1cf66f2 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -10,14 +10,14 @@ services: image: ${IMAGE_REPO}:zammad-postgresql${VERSION} links: - zammad-postgresql - restart: always + restart: ${RESTART} volumes: - zammad-backup:/var/tmp/zammad - zammad-data:/opt/zammad zammad-elasticsearch: image: ${IMAGE_REPO}:zammad-elasticsearch${VERSION} - restart: always + restart: ${RESTART} volumes: - elasticsearch-data:/usr/share/elasticsearch/data @@ -36,7 +36,7 @@ services: zammad-memcached: command: ["zammad-memcached"] image: ${IMAGE_REPO}:zammad-memcached${VERSION} - restart: always + restart: ${RESTART} zammad-nginx: command: ["zammad-nginx"] @@ -46,7 +46,7 @@ services: links: - zammad-railsserver - zammad-websocket - restart: always + restart: ${RESTART} volumes: - zammad-data:/opt/zammad expose: @@ -54,7 +54,7 @@ services: zammad-postgresql: image: ${IMAGE_REPO}:zammad-postgresql${VERSION} - restart: always + restart: ${RESTART} volumes: - postgresql-data:/var/lib/postgresql/data @@ -68,7 +68,7 @@ services: - zammad-elasticsearch - zammad-memcached - zammad-postgresql - restart: always + restart: ${RESTART} volumes: - zammad-data:/opt/zammad @@ -82,7 +82,7 @@ services: - zammad-elasticsearch - zammad-memcached - zammad-postgresql - restart: always + restart: ${RESTART} volumes: - zammad-data:/opt/zammad @@ -95,7 +95,7 @@ services: links: - zammad-postgresql - zammad-memcached - restart: always + restart: ${RESTART} volumes: - zammad-data:/opt/zammad