From 39fded21713efe0a142ab730839e6ee302295ea4 Mon Sep 17 00:00:00 2001 From: kartnico Date: Sat, 15 Jan 2022 10:33:32 +0100 Subject: [PATCH] feat(ng): manage docker network_mode in ng state --- docker/compose/ng.sls | 3 +++ docs/README.rst | 1 + 2 files changed, 4 insertions(+) diff --git a/docker/compose/ng.sls b/docker/compose/ng.sls index f82f381e..d1a873fd 100644 --- a/docker/compose/ng.sls +++ b/docker/compose/ng.sls @@ -36,6 +36,9 @@ docker-compose-ng-{{ id }}-running: - tty: {{ container.tty|default(False) }} {%- if 'command' in container %} - command: {{ container.command }} + {%- endif %} + {%- if 'network_mode' in container %} + - network_mode: {{ container.network_mode }} {%- endif %} {%- if 'working_dir' in container %} - working_dir: {{ container.working_dir }} diff --git a/docs/README.rst b/docs/README.rst index d81fe5a0..ba938495 100644 --- a/docs/README.rst +++ b/docs/README.rst @@ -200,6 +200,7 @@ To use this formula, you might target a host with the following pillar: # image: 'docker.io/nginx:latest' ##Fedora image: 'nginx:latest' container_name: 'nginx-latest' + network_mode: 'bridge' links: - 'registry-service:registry' ports: