From 3de6ebc21e95c264690f46e220dcb789e0282ea5 Mon Sep 17 00:00:00 2001 From: Andy Neff Date: Fri, 28 Apr 2017 18:07:50 -0400 Subject: [PATCH] Update docker-compose index.md (#3090) There were a number of things wrong with the `restart` definition 1. The volumes note came after the restart section rather than before 2. The restart command used array notation rather than map. This is confusing to those unfamiliar with yaml and inconsistent with the rest of the documentation 3. Using `docker-compose` myself, saying `restart: no` does not work, but `restart: "no"` does. ``` ERROR: The Compose file './docker-compose.override.yml' is invalid because: services.letsencrypt.restart contains an invalid type, it should be a string ``` --- compose/compose-file/index.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/compose/compose-file/index.md b/compose/compose-file/index.md index a352333cac..76b627bc45 100644 --- a/compose/compose-file/index.md +++ b/compose/compose-file/index.md @@ -1193,9 +1193,9 @@ See [Docker Volumes](/engine/userguide/dockervolumes.md) and `no` is the default restart policy, and it will not restart a container under any circumstance. When `always` is specified, the container always restarts. The `on-failure` policy restarts a container if the exit code indicates an on-failure error. - - restart: no - - restart: always - - restart: on-failure + restart: "no" + restart: always + restart: on-failure ### domainname, hostname, ipc, mac\_address, privileged, read\_only, shm\_size, stdin\_open, tty, user, working\_dir