Prefering local hosts over truncated one.

This commit is contained in:
Daniel Baumann 2009-01-11 16:21:14 +01:00
parent a7334c6c16
commit 425d51e38b
1 changed files with 6 additions and 1 deletions

View File

@ -77,7 +77,12 @@ EOF
# Creating lock file
Create_lockfile .lock
if [ -f chroot/etc/hosts.orig ]
if [ -e config/chroot_local-includes/etc/hosts ]
then
# Copying local hosts
cp -a config/chroot_local-includes/etc/hosts chroot/etc/hosts
rm -f chroot/etc/hosts.orig
elif [ -f chroot/etc/hosts.orig ]
then
# Restore hosts file
mv chroot/etc/hosts.orig chroot/etc/hosts