summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFlorent Villard <warly@mandriva.com>2003-03-02 12:46:22 +0000
committerFlorent Villard <warly@mandriva.com>2003-03-02 12:46:22 +0000
commitfb900a0d0b5e9db9b1e8330152cfbe29a0b6a9c9 (patch)
treeae59719bf71004f9811a39d31d0c5a5b8047b6e8
parentf3608ba72c38db1a2b7dc21e20f396064c988b2b (diff)
downloaddrakwizard-fb900a0d0b5e9db9b1e8330152cfbe29a0b6a9c9.tar
drakwizard-fb900a0d0b5e9db9b1e8330152cfbe29a0b6a9c9.tar.gz
drakwizard-fb900a0d0b5e9db9b1e8330152cfbe29a0b6a9c9.tar.bz2
drakwizard-fb900a0d0b5e9db9b1e8330152cfbe29a0b6a9c9.tar.xz
drakwizard-fb900a0d0b5e9db9b1e8330152cfbe29a0b6a9c9.zip
start nfs server if not running at the end of nfs wizard
-rw-r--r--ftp_wizard/ftp.wiz3
-rw-r--r--news_wizard/scripts/Newsconf.pm11
-rw-r--r--nfs_wizard/scripts/NFSConf.pm5
3 files changed, 11 insertions, 8 deletions
diff --git a/ftp_wizard/ftp.wiz b/ftp_wizard/ftp.wiz
index fb145044..839e36df 100644
--- a/ftp_wizard/ftp.wiz
+++ b/ftp_wizard/ftp.wiz
@@ -190,7 +190,6 @@
>
</Info>
-
<Info
helpText="Type the path of the directory you want being shared."
>
@@ -201,7 +200,7 @@
variableName="wiz_dir"
fillfunc="get_dir"
helpText="Shared directory:"
- editable="true"
+ editable="true"
>
</Freetext>
diff --git a/news_wizard/scripts/Newsconf.pm b/news_wizard/scripts/Newsconf.pm
index ddd99f6f..10b6bfa6 100644
--- a/news_wizard/scripts/Newsconf.pm
+++ b/news_wizard/scripts/Newsconf.pm
@@ -61,11 +61,12 @@ sub do_it {
$_;
} cat_("__WIZ_HOME__/news_wizard/scripts/config.default"));
$file = "/var/spool/cron/news";
- -f $file and MDK::Common::cp_af($file, "/etc/leafnode/crontab");
- $file = "/etc/leafnode/crontab";
- MDK::Common::cp_af($file, $file . ".orig");
- my $file = "/etc/leafnode/crontab";
- output($file, map {
+ my $file_c = "/etc/leafnode/crontab";
+ if (-f $file) {
+ MDK::Common::cp_af($file, $file_c);
+ MDK::Common::cp_af($file, $file . ".orig");
+ }
+ output($file_c, map {
s|__freq__|$freq|g;
$_;
} cat_("__WIZ_HOME__/news_wizard/scripts/news.cron"));
diff --git a/nfs_wizard/scripts/NFSConf.pm b/nfs_wizard/scripts/NFSConf.pm
index e21327bb..580aa9ef 100644
--- a/nfs_wizard/scripts/NFSConf.pm
+++ b/nfs_wizard/scripts/NFSConf.pm
@@ -19,9 +19,11 @@
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
package NFSConf;
+use lib "/usr/lib/libDrakX";
require "__WIZ_HOME__/common/scripts/Vareqval.pm";
require "__WIZ_HOME__/common/scripts/IFCFG.pm";
use MDK::Common;
+use services;
use strict;
my $o = IFCFG->new();
@@ -60,5 +62,6 @@ sub do_it {
substInFile { s|^(?!\#).*$ENV{wiz_nfs_dir}\s.*|\#$&|} $file;
append_to_file($file, $line);
system("/usr/sbin/exportfs -a");
- 10;
+ services::is_service_running('nfs') and services::start('nfs');
+ 10
}