Only copy resolv.conf from host if it doesn't exist

This commit is contained in:
Adam Schaefers 2019-12-10 01:12:26 -08:00
parent f453d0f99f
commit 9985344d25
No known key found for this signature in database
GPG Key ID: DD4795B51117D906

View File

@ -38,7 +38,7 @@ main() {
}
log Copying /etc/resolv.conf from host; {
[ ! -f "/$1/etc/resolv.conf" ] && cp /etc/resolv.conf "$1/etc"
[ -f "/$1/etc/resolv.conf" ] || cp /etc/resolv.conf "$1/etc"
}
log Entering chroot; {