From 3bc4766f39f454b668ba5986c259081e97b9dd56 Mon Sep 17 00:00:00 2001 From: Justin Cormack Date: Tue, 28 Nov 2017 17:18:17 +0000 Subject: [PATCH] Bind mount /etc/resolv.conf into nginx container Signed-off-by: Justin Cormack --- examples/aws.yml | 2 ++ examples/gcp.yml | 5 +++-- examples/openstack.yml | 2 ++ examples/swap.yml | 2 ++ examples/vmware.yml | 3 ++- examples/vultr.yml | 2 ++ linuxkit.yml | 2 ++ 7 files changed, 15 insertions(+), 3 deletions(-) diff --git a/examples/aws.yml b/examples/aws.yml index 640f44021..a55304b4c 100644 --- a/examples/aws.yml +++ b/examples/aws.yml @@ -29,6 +29,8 @@ services: - CAP_SETUID - CAP_SETGID - CAP_DAC_OVERRIDE + binds: + - /etc/resolv.conf:/etc/resolv.conf trust: org: - linuxkit diff --git a/examples/gcp.yml b/examples/gcp.yml index f7aa28b3c..8ecef6a5a 100644 --- a/examples/gcp.yml +++ b/examples/gcp.yml @@ -33,8 +33,9 @@ services: - CAP_SETUID - CAP_SETGID - CAP_DAC_OVERRIDE + binds: + - /etc/resolv.conf:/etc/resolv.conf trust: org: - linuxkit - image: - - nginx:alpine + - library diff --git a/examples/openstack.yml b/examples/openstack.yml index 8baec9f2f..7a66b822b 100644 --- a/examples/openstack.yml +++ b/examples/openstack.yml @@ -30,6 +30,8 @@ services: - CAP_SETUID - CAP_SETGID - CAP_DAC_OVERRIDE + binds: + - /etc/resolv.conf:/etc/resolv.conf trust: org: - linuxkit diff --git a/examples/swap.yml b/examples/swap.yml index 3e51a2675..2e74ce6c6 100644 --- a/examples/swap.yml +++ b/examples/swap.yml @@ -37,6 +37,8 @@ services: - CAP_SETUID - CAP_SETGID - CAP_DAC_OVERRIDE + binds: + - /etc/resolv.conf:/etc/resolv.conf trust: org: - linuxkit diff --git a/examples/vmware.yml b/examples/vmware.yml index 4799468d8..6a0ae1726 100644 --- a/examples/vmware.yml +++ b/examples/vmware.yml @@ -26,7 +26,8 @@ services: - CAP_SETUID - CAP_SETGID - CAP_DAC_OVERRIDE - net: host + binds: + - /etc/resolv.conf:/etc/resolv.conf trust: org: - linuxkit diff --git a/examples/vultr.yml b/examples/vultr.yml index 54001ca0d..8ecef6a5a 100644 --- a/examples/vultr.yml +++ b/examples/vultr.yml @@ -33,6 +33,8 @@ services: - CAP_SETUID - CAP_SETGID - CAP_DAC_OVERRIDE + binds: + - /etc/resolv.conf:/etc/resolv.conf trust: org: - linuxkit diff --git a/linuxkit.yml b/linuxkit.yml index db7ac5be6..05e3046a7 100644 --- a/linuxkit.yml +++ b/linuxkit.yml @@ -31,6 +31,8 @@ services: - CAP_SETUID - CAP_SETGID - CAP_DAC_OVERRIDE + binds: + - /etc/resolv.conf:/etc/resolv.conf files: - path: etc/containerd/config.toml contents: |