summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMathieu Parent <math.parent@gmail.com>2008-12-30 14:11:58 (GMT)
committerMathieu Parent <math.parent@gmail.com>2008-12-30 14:11:58 (GMT)
commit4e5c5162f733402e18b7cce74d997d797c393a03 (patch)
tree07cd26fc90b94cf0253095620993417f51004b6d
parentafad0a6fd6a7a61c59352d874908072b28190eae (diff)
downloadperl-Kolab-4e5c5162f733402e18b7cce74d997d797c393a03.tar.gz
kolab/issue3321 (slapd.replicas.template and slapd.access.template can be absent)
-rw-r--r--ChangeLog5
-rw-r--r--lib/Kolab/Conf.pm8
2 files changed, 13 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index 3695358..63eae95 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2008-12-30 Mathieu Parent <math.parent@gmail.com>
+
+ * lib/Kolab/Conf.pm.pm: slapd.replicas.template and slapd.access.template
+ can be absent (kolab/issue3321)
+
2008-11-26 Mathieu Parent <math.parent@gmail.com>
* lib/Kolab.pm: Check syncrepl_cookie_file while using `syncrepl'
diff --git a/lib/Kolab/Conf.pm b/lib/Kolab/Conf.pm
index 8ac43a7..3f2e4f9 100644
--- a/lib/Kolab/Conf.pm
+++ b/lib/Kolab/Conf.pm
@@ -484,6 +484,10 @@ sub buildLDAPAccess
my $templatedir = $Kolab::config{"templatedir"};
my $keytemplate = "$templatedir/slapd.access.template";
+ if( ! -f $keytemplate ) {
+ Kolab::log('T', "No LDAP access file `$keytemplate', skipping", KOLAB_DEBUG);
+ return;
+ }
my $cfg = $templates{$keytemplate};
my $oldcfg = $cfg . '.old';
@@ -578,6 +582,10 @@ sub buildLDAPReplicas
my $templatedir = $Kolab::config{"templatedir"};
my $keytemplate = "$templatedir/slapd.replicas.template";
+ if( ! -f $keytemplate ) {
+ Kolab::log('T', "No LDAP replicas `$keytemplate', skipping", KOLAB_DEBUG);
+ return;
+ }
my $cfg = $templates{$keytemplate};
my $oldcfg = $cfg . '.old';