From 2151a1d5c15f9c447477ea11ee1de352e70c4466 Mon Sep 17 00:00:00 2001 From: Adam Spiers Date: Sun, 26 May 2019 11:52:50 +0100 Subject: [PATCH] Set restart policy to unless-stopped If a host is rebooted gracefully or via crash, typically users will want the docker containers to automatically restart. Otherwise Mautic will become unavailable until the next time a human notices the issue and manually restarts the containers, and that could risk an unacceptably long outage period during which Mautic is completely broken. --- examples/mautic-example-nginx-ssl/docker-compose.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/examples/mautic-example-nginx-ssl/docker-compose.yml b/examples/mautic-example-nginx-ssl/docker-compose.yml index d6dc2f32..a26138bf 100644 --- a/examples/mautic-example-nginx-ssl/docker-compose.yml +++ b/examples/mautic-example-nginx-ssl/docker-compose.yml @@ -1,6 +1,7 @@ version: "2" services: mautic: + restart: unless-stopped image: mautic/mautic depends_on: - mysql @@ -12,6 +13,7 @@ services: MAUTIC_DB_PASSWORD: mauticdbpass MAUTIC_TRUSTED_PROXIES: 0.0.0.0/0 mysql: + restart: unless-stopped image: mysql:5.6 environment: MYSQL_ROOT_PASSWORD: mysqlrootpassword @@ -20,6 +22,7 @@ services: MYSQL_PASSWORD: mauticdbpass nginx: + restart: unless-stopped image: nginx ports: - "443:443"