From a46b8b21bfc990332a440d4f1fe727792143dc03 Mon Sep 17 00:00:00 2001 From: Thierry Vignaud Date: Tue, 22 Jul 2003 22:11:56 +0000 Subject: disable service start/stop too in testing mode --- perl-install/standalone/drakgw | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'perl-install/standalone/drakgw') diff --git a/perl-install/standalone/drakgw b/perl-install/standalone/drakgw index 0e11c0afb..c7829d073 100755 --- a/perl-install/standalone/drakgw +++ b/perl-install/standalone/drakgw @@ -69,6 +69,7 @@ sub outpend { } sub start_daemons () { + return if $::testing; my $cups_used = 0; log::explanations("Starting daemons"); if (-f "/etc/rc.d/init.d/cups") { @@ -92,6 +93,7 @@ sub start_daemons () { } sub stop_daemons () { + return if $::testing; log::explanations("Stopping daemons"); foreach (qw(dhcpd named)) { system("/etc/rc.d/init.d/$_ status >/dev/null 2>/dev/null") == 0 and sys("/etc/rc.d/init.d/$_ stop"); @@ -376,7 +378,7 @@ my %rpm2file = ('dhcp-server' => '/usr/sbin/dhcpd', #- first: try to install all in one step my @needed_to_install = grep { !-e $rpm2file{$_} } keys %rpm2file; -@needed_to_install and $in->do_pkgs->install(@needed_to_install); +@needed_to_install and $in->do_pkgs->install(@needed_to_install) if !$::testing; #- second: try one by one if failure detected if (!$::testing && any { !-e $rpm2file{$_} } keys %rpm2file) { foreach (keys %rpm2file) { -- cgit v1.2.1