mirror of
https://github.com/flatcar/scripts.git
synced 2025-10-03 19:42:15 +02:00
coreos-base/oem-gce: Bind mount nsswitch.conf for /etc/hosts
The host's /etc/nsswitch.conf is a symlink to /usr/share/google-oslogin/nsswitch.conf but that is not present in the rkt container. Do not only bind-mount /etc but also the target of the symlink. With a broken nsswitch.conf any entries in /etc/hosts are not considered which makes problems when a custom DNS server is used.
This commit is contained in:
parent
0cc0511167
commit
ccd08f7c32
@ -19,6 +19,8 @@ ExecStart=/usr/bin/rkt run \
|
|||||||
--volume=etc,kind=host,source=/etc,readOnly=false \
|
--volume=etc,kind=host,source=/etc,readOnly=false \
|
||||||
--volume=home,kind=host,source=/home,readOnly=false \
|
--volume=home,kind=host,source=/home,readOnly=false \
|
||||||
--volume=runsystemd,kind=host,source=/run/systemd,readOnly=false \
|
--volume=runsystemd,kind=host,source=/run/systemd,readOnly=false \
|
||||||
|
--volume=nsswitch,kind=host,source=/usr/share/google-oslogin/nsswitch.conf,readOnly=true \
|
||||||
|
--mount=volume=nsswitch,target=/usr/share/google-oslogin/nsswitch.conf \
|
||||||
/usr/share/oem/flatcar-oem-gce.aci
|
/usr/share/oem/flatcar-oem-gce.aci
|
||||||
|
|
||||||
ExecStopPost=/usr/bin/rkt gc --mark-only
|
ExecStopPost=/usr/bin/rkt gc --mark-only
|
||||||
|
Loading…
x
Reference in New Issue
Block a user