summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorOlivier Blin <oblin@mandriva.org>2004-09-01 04:41:14 +0000
committerOlivier Blin <oblin@mandriva.org>2004-09-01 04:41:14 +0000
commit8a2f5e13412eed5bc9816595b1d14482faac68da (patch)
tree9040fa3efc41f0028b834a82b9ebf7e5c5c7934b
parenta441d8a7e9f9e7cd791118c7562749cf1abd8d3c (diff)
downloaddrakx-backup-do-not-use-8a2f5e13412eed5bc9816595b1d14482faac68da.tar
drakx-backup-do-not-use-8a2f5e13412eed5bc9816595b1d14482faac68da.tar.gz
drakx-backup-do-not-use-8a2f5e13412eed5bc9816595b1d14482faac68da.tar.bz2
drakx-backup-do-not-use-8a2f5e13412eed5bc9816595b1d14482faac68da.tar.xz
drakx-backup-do-not-use-8a2f5e13412eed5bc9816595b1d14482faac68da.zip
symlink resolv.conf in install root, so that it works for dhcp too
-rw-r--r--perl-install/network/network.pm8
1 files changed, 4 insertions, 4 deletions
diff --git a/perl-install/network/network.pm b/perl-install/network/network.pm
index 748b31055..5cbf9144a 100644
--- a/perl-install/network/network.pm
+++ b/perl-install/network/network.pm
@@ -422,10 +422,10 @@ sub configureNetwork2 {
if (!$::testing) {
$netc->{wireless_eth} and $in->do_pkgs->ensure_binary_is_installed('wireless-tools', 'iwconfig', 'auto');
write_conf("$etc/sysconfig/network", $netc);
- unless ($netc->{DHCP}) {
- write_resolv_conf("$etc/resolv.conf", $netc);
- #- write in install root too so that updates and suppl media can be added
- write_resolv_conf("/etc/resolv.conf", $netc) if $::isInstall;
+ write_resolv_conf("$etc/resolv.conf", $netc) unless $netc->{DHCP};
+ if ($::isInstall && ! -e "/etc/resolv.conf") {
+ #- symlink resolv.conf in install root too so that updates and suppl media can be added
+ symlink "$etc/resolv.conf", "/etc/resolv.conf";
}
write_interface_conf("$etc/sysconfig/network-scripts/ifcfg-$_->{DEVICE}", $_, $netc, $::prefix) foreach grep { $_->{DEVICE} ne 'ppp0' } values %$intf;
add2hosts("$etc/hosts", $netc->{HOSTNAME}, "127.0.0.1") if $netc->{HOSTNAME};