From 393f47d085126c389bad47555f7a5db63ef2c534 Mon Sep 17 00:00:00 2001 From: strarsis Date: Thu, 16 Mar 2017 16:45:47 +0100 Subject: [PATCH] Add restart: always (#550) * Update docker-compose.yml.dist * Update docker-compose.elk.yml.dist * Update README.md --- README.md | 2 ++ docker-compose.elk.yml.dist | 2 ++ docker-compose.yml.dist | 1 + 3 files changed, 5 insertions(+) diff --git a/README.md b/README.md index 22e5782f..fef98fb9 100644 --- a/README.md +++ b/README.md @@ -42,6 +42,8 @@ Adapt this file with your FQDN. Install [docker-compose](https://docs.docker.com Your configs must be mounted in `/tmp/docker-mailserver/`. To understand how things work on boot, please have a look to [start-mailserver.sh](https://github.com/tomav/docker-mailserver/blob/master/target/start-mailserver.sh) +`restart: always` ensures that the mail server container (and ELK container when using the mail server together with ELK stack) is automatically restarted by Docker in cases like a Docker service or host restart or container exit. + ```yaml version: '2' diff --git a/docker-compose.elk.yml.dist b/docker-compose.elk.yml.dist index 75ffa10e..58c704b9 100644 --- a/docker-compose.elk.yml.dist +++ b/docker-compose.elk.yml.dist @@ -21,6 +21,7 @@ services: - ENABLE_ELK_FORWARDER=1 cap_add: - NET_ADMIN + restart: always elk: build: elk ports: @@ -28,6 +29,7 @@ services: - "9200:9200" - "5044:5044" - "5000:5000" + restart: always volumes: maildata: diff --git a/docker-compose.yml.dist b/docker-compose.yml.dist index d965a9a6..4585eb13 100644 --- a/docker-compose.yml.dist +++ b/docker-compose.yml.dist @@ -23,6 +23,7 @@ services: - DMS_DEBUG=0 cap_add: - NET_ADMIN + restart: always volumes: maildata: