From 738ad81999f3fa26f22988275791af3fc7c92e5d Mon Sep 17 00:00:00 2001 From: Corbin Bartsch Date: Fri, 29 Apr 2022 01:07:25 -0400 Subject: [PATCH 1/2] Add support for logg --- templates/docker-compose.yml.j2 | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/templates/docker-compose.yml.j2 b/templates/docker-compose.yml.j2 index 81b46ed..d5b34ec 100644 --- a/templates/docker-compose.yml.j2 +++ b/templates/docker-compose.yml.j2 @@ -110,6 +110,16 @@ services: - {{ dns_entry }} {% endfor %} {% endif %} +{% if container.logging.driver is defined %} + logging: + driver: {{ container.logging.driver }} +{% if container.logging.options is defined %} + options: +{% for option in container.logging.options %} + {{ option }}: {{ container.logging.options[option] }} +{% endfor %} +{% endif %} +{% endif %} {% if container.restart is defined %} restart: {{ container.restart }} {% endif %} From 639a8f3bc9dd31e2d6167661d016cead7e301cd3 Mon Sep 17 00:00:00 2001 From: Corbin Bartsch Date: Wed, 4 May 2022 06:47:36 -0400 Subject: [PATCH 2/2] Fixed indentation --- templates/docker-compose.yml.j2 | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/templates/docker-compose.yml.j2 b/templates/docker-compose.yml.j2 index d5b34ec..f692cfd 100644 --- a/templates/docker-compose.yml.j2 +++ b/templates/docker-compose.yml.j2 @@ -111,12 +111,12 @@ services: {% endfor %} {% endif %} {% if container.logging.driver is defined %} - logging: - driver: {{ container.logging.driver }} + logging: + driver: {{ container.logging.driver }} {% if container.logging.options is defined %} - options: + options: {% for option in container.logging.options %} - {{ option }}: {{ container.logging.options[option] }} + {{ option }}: {{ container.logging.options[option] }} {% endfor %} {% endif %} {% endif %}