Support dhcpcd in one shot mode as well

This is needed for cloud environments that want to get their metadata in
the onboot phase over the network.

Signed-off-by: Justin Cormack <justin.cormack@docker.com>
This commit is contained in:
Justin Cormack
2017-04-11 14:45:51 +01:00
parent 06ac17821b
commit 2c7628c101
12 changed files with 38 additions and 36 deletions

View File

@@ -81,4 +81,4 @@ trust:
image:
- mobylinux/kernel
outputs:
- format: kernel+initrd
- format: kernel+initrd

View File

@@ -15,7 +15,7 @@ onboot:
- CAP_SYS_ADMIN
services:
- name: dhcpcd
image: "mobylinux/dhcpcd:3eb32da7ff8051f61e0f18edd90dd0fbfcf148ea"
image: "mobylinux/dhcpcd:0d4012269cb142972fed8542fbdc3ff5a7b695cd"
binds:
- /var:/var
- /tmp:/etc

View File

@@ -7,15 +7,8 @@ init:
- mobylinux/containerd:18eaf72f3f4f9a9f29ca1951f66df701f873060b
- mobylinux/ca-certificates:eabc5a6e59f05aa91529d80e9a595b85b046f935
onboot:
- name: check
image: "mobylinux/check:c9e41ab96b3ea6a3ced97634751e20d12a5bf52f"
pid: host
capabilities:
- CAP_SYS_BOOT
readonly: true
services:
- name: dhcpcd
image: "mobylinux/dhcpcd:3eb32da7ff8051f61e0f18edd90dd0fbfcf148ea"
image: "mobylinux/dhcpcd:0d4012269cb142972fed8542fbdc3ff5a7b695cd"
binds:
- /var:/var
- /tmp:/etc
@@ -24,7 +17,13 @@ services:
- CAP_NET_BIND_SERVICE
- CAP_NET_RAW
net: host
oomScoreAdj: -800
command: ["/sbin/dhcpcd", "--nobackground", "-f", "/dhcpcd.conf", "-1"]
- name: check
image: "mobylinux/check:c9e41ab96b3ea6a3ced97634751e20d12a5bf52f"
pid: host
capabilities:
- CAP_SYS_BOOT
readonly: true
outputs:
- format: kernel+initrd
- format: iso-bios

View File

@@ -27,7 +27,7 @@ services:
oomScoreAdj: -800
readonly: true
- name: dhcpcd
image: "mobylinux/dhcpcd:3eb32da7ff8051f61e0f18edd90dd0fbfcf148ea"
image: "mobylinux/dhcpcd:0d4012269cb142972fed8542fbdc3ff5a7b695cd"
binds:
- /var:/var
- /tmp:/etc