From 4401b4fd5cd41589b7675e91b46f19ea05492c4b Mon Sep 17 00:00:00 2001 From: Antoine Ginies Date: Wed, 7 Dec 2005 22:22:54 +0000 Subject: now support virtual interfaces (thx misc) --- dhcp_wizard/Dhcp.pm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'dhcp_wizard') diff --git a/dhcp_wizard/Dhcp.pm b/dhcp_wizard/Dhcp.pm index f92a2c81..7b8f3665 100755 --- a/dhcp_wizard/Dhcp.pm +++ b/dhcp_wizard/Dhcp.pm @@ -71,7 +71,8 @@ $o->{pages} = { ip_range => { name => N("Range of addresses used by DHCP") . "\n\n\n" . N("Select the range of addresses assigned to the workstations by the DHCP service; unless you have special needs, you can safely accept the proposed values. (ie: 192.168.100.20 192.168.100.40)") . "\n\n" . N("If you want to enable PXE in your dhcp server please check the box (Pre-boot eXecution Environment, a protocol that allows computers to boot through the network)."), pre => sub { - ($wiz_ip_server) = `/sbin/ip addr show dev $o->{var}{interface}` =~ /^\s*inet\s+(\d+\.\d+\.\d+\.\d+)/m; + #($wiz_ip_server) = `/sbin/ip addr show dev $o->{var}{interface}` =~ /^\s*inet\s+(\d+\.\d+\.\d+\.\d+)/m; + ($wiz_ip_server) = $wiz->{net}->{itf}{$o->{var}{interface}}{IPADDR}; $wiz_tftpserverip = $wiz_ip_server; my $d = $4 if $wiz_ip_server =~ /(\d{1,3})\.(\d{1,3})\.(\d{1,3})\.(\d{1,3})/; my $s = "$1.$2.$3" if $wiz_ip_server =~ /(\d{1,3})\.(\d{1,3})\.(\d{1,3})\.(\d{1,3})/; -- cgit v1.2.1