From 986a271663c7f37797bec011b2ee9379e82ac4fe Mon Sep 17 00:00:00 2001 From: Florent Villard Date: Wed, 17 Sep 2003 17:41:09 +0000 Subject: better check of ip addresses in dhcp check that server has been run in client dns check that the program is run as root in drakwizard remove bad quotes in po --- client_wizard/Bind_client.pm | 25 +++++++++++++++---------- 1 file changed, 15 insertions(+), 10 deletions(-) (limited to 'client_wizard') diff --git a/client_wizard/Bind_client.pm b/client_wizard/Bind_client.pm index 799d38f7..932155ca 100755 --- a/client_wizard/Bind_client.pm +++ b/client_wizard/Bind_client.pm @@ -38,8 +38,14 @@ my $o = { client_ip => '', client_name => '' }, - needed_rpm => [ ], - defaultimage => "$ENV{__WIZ_HOME__}client_wizard/images/DNS.png" + needed_rpm => [ ], + defaultimage => "$ENV{__WIZ_HOME__}client_wizard/images/DNS.png", + init => sub { + if (! -f "/var/named/$wiz_domain_name.db") { + return (0, N('You must first run the DNS server wizard')) + } + 1 + } }; $o->{pages} = { @@ -62,18 +68,18 @@ $o->{pages} = { next => 'summary' }, dhcp_warning => { - name => N('Warning'), - data => [ { label => N('You are in dhcp, server may not work with your configuration.') } ], + name => N('Warning') . "\n\n" . N('You are in dhcp, server may not work with your configuration.'), + ignore => 1, next => 'client_id' }, system_error => { - name => N('Error'), - data => [ { label => N('System error, no configuration done') } ], + name => N('Error') . "\n\n" . N('System error, no configuration done'), + ignore => 1, next => 'client_id' }, error => { - name => N('Error'), - data => [ { label => N('This is not a valid address... press next to continue') } ], + name => N('Error') . "\n\n" . N('This is not a valid address... press next to continue'), + ignore => 1, next => 'client_id' }, summary => { @@ -86,8 +92,7 @@ $o->{pages} = { next => 'end' }, end => { - name => N('Congratulations'), - data => [ { label => N('The wizard successfully added the client.') } ], + name => N('Congratulations') . "\n\n" . N('The wizard successfully added the client.'), end => 1, next => 0 }, -- cgit v1.2.1