If no resolv.conf has been made for the new system already and the install

media has one already, copy it in lieu of leaving things blank. This
reduces the foot-shooting potential for PXE installs that immediately
add packages.
This commit is contained in:
Nathan Whitehorn 2013-01-27 23:12:37 +00:00
parent 0de8cf6314
commit 4bdf739335
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=246013

View File

@ -68,6 +68,11 @@ bsdinstall distextract
# Finalize install
bsdinstall config
# Make sure networking is functional, if we can arrange that
if [ ! -f $BSDINSTALL_CHROOT/etc/resolv.conf -a -f /etc/resolv.conf ]; then
cp /etc/resolv.conf $BSDINSTALL_CHROOT/etc/resolv.conf
fi
# Run post-install script
if [ -f /tmp/bsdinstall-installscript-ab ]; then
cp /tmp/bsdinstall-installscript-ab $BSDINSTALL_CHROOT/tmp/installscript