From: Daan De Meyer Date: Mon, 7 Aug 2023 18:17:41 +0000 (+0200) Subject: mkosi: Unmount /etc/resolv.conf if it's a mountpoint X-Git-Tag: v255-rc1~799 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=b57e7522209c8bdff6e0970d0fc4a7ec92ea50fe;p=thirdparty%2Fsystemd.git mkosi: Unmount /etc/resolv.conf if it's a mountpoint --- diff --git a/mkosi.presets/20-final/mkosi.postinst b/mkosi.presets/20-final/mkosi.postinst index 3f3a78e9063..663fa5c762e 100755 --- a/mkosi.presets/20-final/mkosi.postinst +++ b/mkosi.presets/20-final/mkosi.postinst @@ -76,7 +76,9 @@ if command -v authselect >/dev/null; then fi fi -# Let tmpfiles.d/systemd-resolve.conf handle the symlink +# Let tmpfiles.d/systemd-resolve.conf handle the symlink. /etc/resolv.conf might be mounted over so undo that +# if that's the case. +mountpoint -q /etc/resolv.conf && umount /etc/resolv.conf rm -f /etc/resolv.conf . /usr/lib/os-release