arch-chroot: don't require /etc/resolv.conf in the host

mansplaining emails shouldn't inspire me to fix things, but here we are.
This commit is contained in:
Dave Reisner 2018-02-03 09:44:04 -05:00
parent cdb25e135b
commit e4be695f33

View File

@ -19,6 +19,8 @@ EOF
chroot_add_resolv_conf() {
local chrootdir=$1 resolv_conf=$1/etc/resolv.conf
[[ -e /etc/resolv.conf ]] || return 0
# Handle resolv.conf as a symlink to somewhere else.
if [[ -L $chrootdir/etc/resolv.conf ]]; then
# readlink(1) should always give us *something* since we know at this point