diff options
author | Antoine Ginies <aginies@mandriva.com> | 2004-10-04 01:21:16 +0000 |
---|---|---|
committer | Antoine Ginies <aginies@mandriva.com> | 2004-10-04 01:21:16 +0000 |
commit | bcc0873b597f769bd3c61f78df83de8ff4ac7964 (patch) | |
tree | 20bee10ca46108f0e5de4bf001cd0332e5cdc82c | |
parent | 34372f327a1ba92e9497fce81479017b6216f447 (diff) | |
download | drakwizard-bcc0873b597f769bd3c61f78df83de8ff4ac7964.tar drakwizard-bcc0873b597f769bd3c61f78df83de8ff4ac7964.tar.gz drakwizard-bcc0873b597f769bd3c61f78df83de8ff4ac7964.tar.bz2 drakwizard-bcc0873b597f769bd3c61f78df83de8ff4ac7964.tar.xz drakwizard-bcc0873b597f769bd3c61f78df83de8ff4ac7964.zip |
- call correct kolab_boostrap script (jmdault)
- use needed_rpm
-rwxr-xr-x | kolab_wizard/Kolab.pm | 39 |
1 files changed, 4 insertions, 35 deletions
diff --git a/kolab_wizard/Kolab.pm b/kolab_wizard/Kolab.pm index 4e7628c5..0ecec1f0 100755 --- a/kolab_wizard/Kolab.pm +++ b/kolab_wizard/Kolab.pm @@ -34,7 +34,7 @@ if (!$IPSERVER) { ($IPSERVER) = `/sbin/ip addr show dev $interface` =~ /^\s*inet\s+(\d+\.\d+\.\d+\.\d+)/m; } my $DOMAINNAME = chomp_(`dnsdomainname`); -my $kolab_config = "/etc/kolab/kolab.conf"; +#my $kolab_config = "/etc/kolab/kolab.conf"; my $o = { name => N("Kolab configuration wizard"), @@ -50,7 +50,7 @@ my $o = { maildomain => $DOMAINNAME, password => '', }, -# needed_rpm => [ 'proftpd', 'openldap-servers', 'apache2', 'kolab-server' ], + needed_rpm => [ 'proftpd', 'openldap-servers', 'apache2', 'kolab-server' ], # defaultimage => $ENV{__WIZ_HOME__}, }; @@ -119,56 +119,25 @@ sub rpm_needed_kolab { sub new { my ($class) = @_; - rpm_needed_kolab(); +# rpm_needed_kolab(); bless { o => $o, }, $class; } -sub backup_conf { - my @conf = qw(/etc/postfix/main.cf - /etc/postfix/master.cf - /etc/postfix/transport - /etc/postfix/virtual - /etc/cyrus.conf - /etc/imapd.conf - /etc/proftpd.conf - /etc/openldap/slapd.conf - /etc/sysconfig/saslauthd - ); - - foreach (@conf) { - -f $_ and MDK::Common::cp_af($_, $_.".orig"); - } - cp_af("/var/lib/ldap/", "/var/lib/ldap.orig"); -} - -sub check_password { - -} - - sub do_it { return if $::testing; my $in = 'interactive'->vnew('su', 'Kolab server'); my $w = $in->wait_message(N("Kolab server"), N("Configuring Kolab server on your system...")); - backup_conf(); - system("service $_ stop") foreach qw(ldap saslauthd cyrus-imapd httpd postfix); - system("groupadd -g 60001 kolab"); local *F; - open(F, "|/usr/sbin/kolab_bootstrap.real -b\n"); + open(F, "|/usr/sbin/kolab_bootstrap -b\n"); print F "$o->{var}{HOSTNAME} $o->{var}{maildomain} $o->{var}{password} "; close F; - substInFile { - s/bind_pw :.*/bind_pw : $o->{var}{password}/; - } $kolab_config; - - system("chkconfig --level 35 $_ off") foreach qw(ldap saslauthd cyrus-imapd httpd postfix); system("service kolab-server restart"); undef $w; } |