21 commits - bin/rebuild.sh.in configure.ac Makefile.am pykolab/auth pykolab/Makefile.am pykolab/setup pykolab/utils.py share/Makefile.am share/templates

Jeroen van Meeuwen vanmeeuwen at kolabsys.com
Sat May 5 16:55:36 CEST 2012


 Makefile.am                                             |    1 
 bin/rebuild.sh.in                                       |   63 ++++
 configure.ac                                            |    3 
 pykolab/Makefile.am                                     |    2 
 pykolab/auth/ldap/__init__.py                           |    4 
 pykolab/setup/setup_mta.py                              |   10 
 pykolab/setup/setup_roundcube.py                        |   15 -
 pykolab/utils.py                                        |    3 
 share/Makefile.am                                       |   22 +
 share/templates/freebusy/config.php.tpl                 |  212 ++++++++++++++++
 share/templates/horde/conf.d/10-kolab_conf_base.php.tpl |   66 ++++
 share/templates/master.cf.tpl                           |   16 -
 share/templates/roundcubemail/main.inc.php.tpl          |    2 
 share/templates/zpush/config.php.tpl                    |  106 ++++++++
 14 files changed, 506 insertions(+), 19 deletions(-)

New commits:
commit 0d0a51065a6780dc40c21ff4250f6cb6b7db7896
Author: Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen at kolabsys.com>
Date:   Sat May 5 15:44:03 2012 +0100

    Bump pre-release

diff --git a/configure.ac b/configure.ac
index 58864aa..0caa293 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,5 +1,5 @@
 AC_INIT([pykolab], 0.4)
-AC_SUBST([RELEASE], 0.13)
+AC_SUBST([RELEASE], 0.14)
 
 AC_CONFIG_SRCDIR(pykolab/constants.py.in)
 


commit 7f9167d2726d7cc48c85fcc36c06ea5a6db80add
Author: Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen at kolabsys.com>
Date:   Sat May 5 15:43:11 2012 +0100

    Add rebuild.sh.in to GIT

diff --git a/bin/rebuild.sh.in b/bin/rebuild.sh.in
new file mode 100644
index 0000000..1e35ce0
--- /dev/null
+++ b/bin/rebuild.sh.in
@@ -0,0 +1,63 @@
+#!/bin/bash
+
+package=@PACKAGE@
+version=@VERSION@
+release=@RELEASE@
+
+srpmdir=`rpm --eval="%{_srcrpmdir}"`
+
+declare -a dists
+declare -a dist_tags
+declare -a product_series
+
+declare -a answers
+declare -a tasks
+
+dists[${#dists[@]}]='f16';  dist_tags[${#dist_tags[@]}]='fc16'; product_series[${#product_series[@]}]="3.0"
+dists[${#dists[@]}]='f17';  dist_tags[${#dist_tags[@]}]='fc17'; product_series[${#product_series[@]}]="3.0"
+dists[${#dists[@]}]='el5';  dist_tags[${#dist_tags[@]}]='el5';  product_series[${#product_series[@]}]="2.4"
+dists[${#dists[@]}]='el6';  dist_tags[${#dist_tags[@]}]='el6';  product_series[${#product_series[@]}]="2.4"
+dists[${#dists[@]}]='el6';  dist_tags[${#dist_tags[@]}]='el6';  product_series[${#product_series[@]}]="3.0"
+
+autoreconf -v && ./configure && make dist || exit 1
+
+x=0
+while [ $x -lt ${#dists[@]} ]; do
+
+    read -p "Build for ${dists[$x]} / ${product_series[$x]}? [Y/n]: " answers[${#answers[@]}]
+
+    if [ "${answers[$x]}" != "n" ]; then
+        answers[$x]="y"
+    fi
+    let x++
+done
+
+x=0
+while [ $x -lt ${#dists[@]} ]; do
+    if [ "${answers[$x]}" == "y" ]; then
+        rpmbuild --define="dist .${dist_tags[$x]}.kolab_${product_series[$x]}" -ts ${package}-${version}.tar.gz
+        tasks[${#tasks[@]}]=`koji build --nowait \
+            feature-${dists[$x]}-kolab-${product_series[$x]}-development \
+            ${srpmdir}/${package}-${version}-${release}.${dist_tags[$x]}.kolab_${product_series[$x]}.src.rpm 2>&1 | \
+            grep "^Created task:" | awk '{print $3}'`
+    fi
+
+    let x++
+done
+
+koji watch-task ${tasks[@]}
+
+x=0
+while [ $x -lt ${#dists[@]} ]; do
+    if [ "${answers[$x]}" == "y" ]; then
+        koji wait-repo \
+            --build=${package}-${version}-${release}.${dist_tags[$x]}.kolab_${product_series[$x]} \
+            feature-${dists[$x]}-kolab-${product_series[$x]}-development-build &
+    fi
+
+    let x++
+done
+
+wait
+
+echo "All done."


commit 3912777a8cb8e5a0a2bd6eb48069095c5e3ce205
Author: Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen at kolabsys.com>
Date:   Sat May 5 15:28:32 2012 +0100

    Bump pre-release

diff --git a/configure.ac b/configure.ac
index 7709a96..58864aa 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,5 +1,5 @@
 AC_INIT([pykolab], 0.4)
-AC_SUBST([RELEASE], 0.12)
+AC_SUBST([RELEASE], 0.13)
 
 AC_CONFIG_SRCDIR(pykolab/constants.py.in)
 


commit a7113ee384f490df83ef0ecf41df94eb58755a69
Author: Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen at kolabsys.com>
Date:   Sat May 5 15:28:04 2012 +0100

    Add a rebuild.sh for my own personal convenience

diff --git a/Makefile.am b/Makefile.am
index 8eca568..00d2529 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -21,6 +21,7 @@ PYTHON_FILES = \
 	wallace.py
 
 EXTRA_DIST = \
+	bin/rebuild.sh.in \
 	AUTHORS \
 	ChangeLog \
 	COPYING \
diff --git a/configure.ac b/configure.ac
index 3adc850..7709a96 100644
--- a/configure.ac
+++ b/configure.ac
@@ -28,6 +28,7 @@ AM_CONDITIONAL([ENTERPRISE], [test "${enterprise}" = "true"])
 AC_SUBST(DATESTAMP,`date +"%a %b %d %Y"`)
 
 AC_CONFIG_FILES([
+bin/rebuild.sh
 Makefile
 pykolab.spec
 conf/Makefile


commit 5fe4069058cc921c6183f3184bd91ea5a9b35ea9
Author: Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen at kolabsys.com>
Date:   Sat May 5 15:27:13 2012 +0100

    Correct variables in zpush configuration template

diff --git a/share/templates/zpush/config.php.tpl b/share/templates/zpush/config.php.tpl
index de30af7..9480ae4 100644
--- a/share/templates/zpush/config.php.tpl
+++ b/share/templates/zpush/config.php.tpl
@@ -19,7 +19,7 @@
     }
 
     // Defines the base path on the server, terminated by a slash
-    define('BASE_PATH', dirname($_SERVER['SCRIPT_FILENAME']) . "/");
+    define('BASE_PATH', dirname(\$_SERVER['SCRIPT_FILENAME']) . "/");
 
     // Define the include paths
     ini_set(
@@ -56,7 +56,7 @@
     define('SYNC_CONFLICT_DEFAULT', SYNC_CONFLICT_OVERWRITE_PIM);
 
     // The data providers that we are using (see configuration below
-    $BACKEND_PROVIDER = "BackendKolab";
+    \$BACKEND_PROVIDER = "BackendKolab";
 
     define("KOLAB_LDAP_ACL","");
     define('KOLAB_IMAP_NAMESPACES', Array(


commit a355e652a7b0d271247dfdf9304c00e8814465c4
Author: Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen at kolabsys.com>
Date:   Sat May 5 14:12:21 2012 +0100

    Bump pre-release

diff --git a/configure.ac b/configure.ac
index bab788f..3adc850 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,5 +1,5 @@
 AC_INIT([pykolab], 0.4)
-AC_SUBST([RELEASE], 0.11)
+AC_SUBST([RELEASE], 0.12)
 
 AC_CONFIG_SRCDIR(pykolab/constants.py.in)
 


commit 5ee3071696cdde66a26b8366b1b99ff0d6f307fe
Author: Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen at kolabsys.com>
Date:   Sat May 5 14:11:02 2012 +0100

    Correct smtpd_*_restrictions referring to a variable that is going to be expanded during parsing

diff --git a/share/templates/master.cf.tpl b/share/templates/master.cf.tpl
index 139313e..df22651 100644
--- a/share/templates/master.cf.tpl
+++ b/share/templates/master.cf.tpl
@@ -19,9 +19,9 @@ submission inet n       -       n       -       -       smtpd
     -o smtpd_sasl_auth_enable=yes
     -o smtpd_sasl_authenticated_header=yes
     -o smtpd_client_restrictions=permit_sasl_authenticated,reject
-    -o smtpd_data_restrictions=$submission_data_restrictions
-    -o smtpd_recipient_restrictions=$submission_recipient_restrictions
-    -o smtpd_sender_restrictions=$submission_sender_restrictions
+    -o smtpd_data_restrictions=\$submission_data_restrictions
+    -o smtpd_recipient_restrictions=\$submission_recipient_restrictions
+    -o smtpd_sender_restrictions=\$submission_sender_restrictions
 
 #smtps     inet  n       -       n       -       -       smtpd
 #  -o syslog_name=postfix/smtps


commit af9a357a6b13874ec6e1ccf30da00ef091a1d6d6
Author: Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen at kolabsys.com>
Date:   Sat May 5 14:09:55 2012 +0100

    Flush stderr and stdout when asking a question

diff --git a/pykolab/utils.py b/pykolab/utils.py
index e3e2e7b..63aacb7 100644
--- a/pykolab/utils.py
+++ b/pykolab/utils.py
@@ -46,6 +46,9 @@ def ask_question(question, default="", password=False):
         else:
             answer = raw_input("%s [%s]: " % (question, default))
 
+    sys.stderr.flush()
+    sys.stdout.flush()
+
     if answer == "":
         return default
     else:


commit 62c419ed0ccac9faa4b3ce4afb7daaaaf43236c7
Author: Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen at kolabsys.com>
Date:   Sat May 5 13:12:48 2012 +0100

    Bump pre-release

diff --git a/configure.ac b/configure.ac
index 7179101..bab788f 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,5 +1,5 @@
 AC_INIT([pykolab], 0.4)
-AC_SUBST([RELEASE], 0.10)
+AC_SUBST([RELEASE], 0.11)
 
 AC_CONFIG_SRCDIR(pykolab/constants.py.in)
 


commit 10050ea8c4393e7a79ed0844757259b7224911b4
Author: Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen at kolabsys.com>
Date:   Sat May 5 02:12:00 2012 +0100

    Add freebusy configuration file

diff --git a/share/Makefile.am b/share/Makefile.am
index 8a6dd94..364bd36 100644
--- a/share/Makefile.am
+++ b/share/Makefile.am
@@ -1,8 +1,11 @@
 templatedir = $(datadir)/kolab/templates
-
 template_DATA = \
 	$(wildcard templates/*.tpl)
 
+fbtemplatedir = $(datadir)/kolab/templates/freebusy
+fbtemplate_DATA = \
+	$(wildcard templates/freebusy/*.tpl)
+
 hordetemplatedir = $(datadir)/kolab/templates/horde/conf.d/
 hordetemplate_DATA = \
 	$(wildcard templates/horde/conf.d/*.tpl)
@@ -24,6 +27,7 @@ EXTRA_DIST = \
 install-exec-local:
 	mkdir -p \
 		$(DESTDIR)/$(sysconfdir)/kolab/templates \
+		$(DESTDIR)/$(sysconfdir)/kolab/templates/freebusy \
 		$(DESTDIR)/$(sysconfdir)/kolab/templates/horde/conf.d \
 		$(DESTDIR)/$(sysconfdir)/kolab/templates/roundcubemail \
 		$(DESTDIR)/$(sysconfdir)/kolab/templates/zpush
diff --git a/share/templates/freebusy/config.php.tpl b/share/templates/freebusy/config.php.tpl
new file mode 100644
index 0000000..f41195a
--- /dev/null
+++ b/share/templates/freebusy/config.php.tpl
@@ -0,0 +1,212 @@
+<?php
+/**
+ * This file provides configuration settings for both the freebusy.php
+ * and the pfb.php scripts.
+ *
+ * \$Horde: framework/Kolab_FreeBusy/www/Horde/Kolab/FreeBusy/config.php,v 1.4.2.2 2010/07/22 13:55:30 wrobel Exp \$
+ *
+ * Copyright 2008-2009 The Horde Project (http://www.horde.org/)
+ *
+ * @author  Steffen Hansen <steffen at klaralvdalens-datakonsult.se>
+ * @author  Gunnar Wrobel <p at rdus.de>
+ * @author  Thomas Arendsen Hein <thomas at intevation.de>
+ * @package Kolab_FreeBusy
+ */
+
+\$conf = array();
+
+/* Horde::Log configuration */
+\$conf['log']['enabled']          = true;
+\$conf['log']['priority']         = PEAR_LOG_DEBUG;
+\$conf['log']['type']             = 'file';
+\$conf['log']['name']             = '/var/log/kolab/freebusy/freebusy.log';
+\$conf['log']['ident']            = 'Kolab Free/Busy';
+\$conf['log']['params']['append'] = true;
+
+/* PHP error logging */
+ini_set('error_log', '/var/log/kolab/freebusy/php.log');
+
+/* Horde::Kolab::LDAP configuration */
+\$conf['kolab']['ldap']['server'] = 'localhost';
+\$conf['kolab']['ldap']['basedn'] = '$ldap_base_dn';
+\$conf['kolab']['ldap']['phpdn']  = '$ldap_service_bind_dn';
+\$conf['kolab']['ldap']['phppw']  = '$ldap_service_bind_pw';
+
+/* Horde::Kolab::IMAP configuration */
+\$conf['kolab']['imap']['server']   = 'localhost';
+\$conf['kolab']['imap']['port']     = 143;
+\$conf['kolab']['imap']['protocol'] = 'imap/tls/novalidate-cert/readonly';
+\$conf['kolab']['imap']['namespaces'] = array(
+    array('type' => 'personal', 'name' => '', 'delimiter' => '/'),
+    array('type' => 'other', 'name' => 'Other Users', 'delimiter' => '/'),
+    array('type' => 'shared', 'name' => 'Shared Folders', 'delimiter' => '/'),
+);
+
+/* Horde::Auth configuration */
+\$conf['auth']['params']['login_block'] = 0;
+\$conf['auth']['checkbrowser']          = false;
+\$conf['auth']['checkip']               = false;
+\$conf['umask'] = false;
+
+\$conf['auth']['driver'] = 'imap';
+\$conf['auth']['params']['hostspec'] = 'localhost';
+\$conf['auth']['params']['protocol'] = 'imap/tls/novalidate-cert';
+
+/* Allow special users to log into the system */
+\$conf['kolab']['imap']['allow_special_users'] = true;
+
+/* Do not record login attempts */
+\$conf['auth']['params']['login_block'] = false;
+
+/* Kolab::Freebusy configuration */
+
+/* Should we redirect using a Location header, if the user is not local? If this
+ * is false we silently download the file ourselves and output it so that it
+ * looks as though the free/busy information is coming from us.
+ */
+\$conf['fb']['redirect']     = false;
+
+/* What is the address of the current server where the calendar data is stored?
+ * This is also used as the LDAP server address where user objects reside.
+ */
+\$conf['kolab']['freebusy']['server']  = 'http://' . \$_SERVER["HTTP_HOST"] . '/freebusy';
+
+/* What is our default mail domain? This is used if any users do not have
+ * '@domain' specified after their username as part of their email address.
+ */
+\$conf['fb']['email_domain'] = '$primary_domain';
+
+/* Location of the cache files */
+\$conf['fb']['cache_dir']    = '/tmp';
+\$conf['fb']['cache']['driver'] = 'sql';
+\$conf['fb']['cache']['params']['phptype'] = 'mysql';
+\$conf['fb']['cache']['params']['username'] = 'roundcube';
+\$conf['fb']['cache']['params']['password'] = '$mysql_roundcube_password';
+\$conf['fb']['cache']['params']['hostspec'] = 'localhost';
+\$conf['fb']['cache']['params']['database'] = 'roundcube';
+\$conf['fb']['cache']['params']['charset'] = 'utf-8';
+
+/* What db type to use for the freebusy caches */
+\$conf['fb']['dbformat']     = 'db4';
+
+/* Should we send a Content-Type header, indicating what the mime type of the
+ * resulting VFB file is?
+ */
+\$conf['fb']['send_content_type'] = false;
+
+/* Should we send a Content-Length header, indicating how large the resulting
+ * VFB file is?
+ */
+\$conf['fb']['send_content_length'] = false;
+
+/* Should we send a Content-Disposition header, indicating what the name of the
+ * resulting VFB file should be?
+ */
+\$conf['fb']['send_content_disposition'] = false;
+
+/* Should we use ACLs or does everybody get full rights? DO NOT set
+ * this to false if you don't know what you are doing. Your free/busy
+ * service should not be visible to any outside networks when
+ * disabling the use of ACL settings.
+ */
+\$conf['fb']['use_acls'] = true;
+
+/* How many days in advance should the free/busy information be calculated? This
+ * is the default value that can be overwritten by the kolabFreeBusyFuture
+ * attribute of the users LDAP account.
+ */
+\$conf['fb']['future_days'] = 180;
+
+/* The resulting vCalendar file is being cached. The following setting
+ * determines how many seconds it will be delivered without checking if
+ * the contents of the file might have changed. A negative setting disables
+ * caching (which is currently required for the resource management to work).
+ */
+\$conf['fb']['vcal_cache']['min_age'] = -1;
+
+/* The resulting vCalendar file is being cached. The following setting
+ * determines after how many seconds it will be considered too old for
+ * delivery and a refresh of its contents will be enforced.
+ */
+\$conf['fb']['vcal_cache']['max_age'] = 259200;
+
+/* The IMAP namespaces on the server. @TODO: Should obviously be
+ * auto-detected.
+ */
+\$conf['fb']['namespace']['personal'] = '';
+\$conf['fb']['namespace']['other'] = 'Other Users';
+
+/* In most cases you can rely on the standard event status to free/busy status
+ * mapping. For the default kolab server this will mean that only the event
+ * status "free" will be mapped to the free/busy status "FREE". All other event
+ * status ("tentative", "busy", "outofoffice") will be mapped to "BUSY".
+ *
+ * If this mapping should be modified you can define it like this:
+ *
+ * \$conf['fb']['status_map'] = array(
+ *    Horde_Kolab_FreeBusy_Object_Event::STATUS_TENTATIVE =>
+ *    Horde_Kolab_FreeBusy_Helper_Freebusy_StatusMap::STATUS_BUSY_TENTATIVE,
+ *    Horde_Kolab_FreeBusy_Object_Event::STATUS_OUTOFOFFICE =>
+ *    'X-OUT-OF-OFFICE',
+ * );
+ */
+require_once 'Horde/Kolab/FreeBusy/Object/Event.php';
+require_once 'Horde/Kolab/FreeBusy/Helper/Freebusy/StatusMap.php';
+\$conf['fb']['status_map'] = array(
+    Horde_Kolab_FreeBusy_Object_Event::STATUS_TENTATIVE =>
+    Horde_Kolab_FreeBusy_Helper_Freebusy_StatusMap::STATUS_BUSY_TENTATIVE,
+    Horde_Kolab_FreeBusy_Object_Event::STATUS_OUTOFOFFICE =>
+    'X-OUT-OF-OFFICE',
+);
+
+/* Are there remote servers on which users have additional (shared)
+ * folders? In that case free/busy information should also be fetched
+ * from these servers.
+ *
+ * Add them like this:
+ *
+ * array('remote1.example.com', 'remote2.example.com')
+ */
+\$conf['fb']['remote_servers'] = array();
+
+/* Is there an exchange server that you want to relay through this free/busy
+ * application?
+ *
+ * Configure it like this:
+ *
+ * \$conf['fb']['exchange_server'] = array(
+ *    'url' => 'https://example.com',
+ *    'interval' => 30,
+ * );
+ */
+#\$conf['fb']['exchange_server'] = array(
+#    'url' => 'http://test90-9.test90.kolabsys.com',
+#    'interval' => 30,
+#    'username' => 'kolabservice',
+#    'password' => 'SomePass',
+#);
+
+/**
+ * Ensure we use the Kolab group driver when handling groups.
+ */
+\$conf['group']['driver'] = 'kolab';
+\$conf['group']['cache'] = false;
+
+//!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+//
+// If you modify this file, please do not forget to also modify the
+// template in kolabd!
+//
+//!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
+
+// DEBUGGING
+// =========
+//
+// Activate this to see the log messages on the screen
+// \$conf['log']['type'] = 'display';
+//
+// Activate this to see the php messages on the screen
+// ini_set('display_errors', 1);
+//
+// Both settings will disrupt header delivery (which should not cause a
+// problem).


commit 36db38827d97a769e92a01727389a47491034577
Author: Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen at kolabsys.com>
Date:   Sat May 5 02:04:57 2012 +0100

    Add zpush configuration file template

diff --git a/share/templates/zpush/config.php.tpl b/share/templates/zpush/config.php.tpl
new file mode 100644
index 0000000..de30af7
--- /dev/null
+++ b/share/templates/zpush/config.php.tpl
@@ -0,0 +1,106 @@
+<?php
+    /***********************************************
+    * File      :   config.php
+    * Project   :   Z-Push
+    * Descr     :   Main configuration file
+    *
+    */
+
+    define('KOLAB_SERVER', "$ldap_ldap_uri");
+    define('KOLAB_LDAP_BASE',"$ldap_base_dn");
+    define('KOLAB_BIND_DN',"$ldap_service_bind_dn");
+    define('KOLAB_BIND_PW',"$ldap_service_bind_pw");
+    define("KOLAB_LDAP_ACL","");
+    define('KOLAB_IMAP_SERVER', "$imap_server");
+
+    // Defines the default time zone
+    if (function_exists("date_default_timezone_set")){
+        date_default_timezone_set(date_default_timezone_get());
+    }
+
+    // Defines the base path on the server, terminated by a slash
+    define('BASE_PATH', dirname($_SERVER['SCRIPT_FILENAME']) . "/");
+
+    // Define the include paths
+    ini_set(
+            'include_path',
+            BASE_PATH . "include/" . PATH_SEPARATOR .
+            BASE_PATH . PATH_SEPARATOR .
+            ini_get('include_path') . PATH_SEPARATOR .
+            "/usr/share/php/" . PATH_SEPARATOR .
+            "/usr/share/php5/" . PATH_SEPARATOR .
+            "/usr/share/pear/"
+    );
+
+    define('STATE_DIR', 'state');
+
+    // Try to set unlimited timeout
+    define('SCRIPT_TIMEOUT', 0);
+
+    //Max size of attachments to display inline. Default is 1MB
+    define('MAX_EMBEDDED_SIZE', 1048576);
+
+    // Device Provisioning
+    define('PROVISIONING', true);
+
+    // This option allows the 'loose enforcement' of the provisioning policies for older
+    // devices which don't support provisioning (like WM 5 and HTC Android Mail) - dw2412 contribution
+    // false (default) - Enforce provisioning for all devices
+    // true - allow older devices, but enforce policies on devices which support it
+    define('LOOSE_PROVISIONING', false);
+    // Default conflict preference
+    // Some devices allow to set if the server or PIM (mobile)
+    // should win in case of a synchronization conflict
+    //   SYNC_CONFLICT_OVERWRITE_SERVER - Server is overwritten, PIM wins
+    //   SYNC_CONFLICT_OVERWRITE_PIM    - PIM is overwritten, Server wins (default)
+    define('SYNC_CONFLICT_DEFAULT', SYNC_CONFLICT_OVERWRITE_PIM);
+
+    // The data providers that we are using (see configuration below
+    $BACKEND_PROVIDER = "BackendKolab";
+
+    define("KOLAB_LDAP_ACL","");
+    define('KOLAB_IMAP_NAMESPACES', Array(
+                'personal' => "",
+                'shared' => "Shared Folders",
+                'users' => "Other Users"
+            )
+        );
+
+    define('KOLAB_IMAP_PORT', 143);
+    define('KOLAB_IMAP_OPTIONS', "/tls/novalidate-cert");
+
+    define('KOLAB_INDEX',"/var/cache/kolab/z-push/kolabindex");
+
+    //KolabMode
+    //  0 = FlatMode
+    //  1 = FolderMode
+    //  2 = try to determine the mode
+    define("KOLAB_MODE",2);
+    // define which mobile support foldermode
+    // this list is checked if KOLAB_MODE is set to 2
+    define("KOLAB_MOBILES_FOLDERMODE","iphone:ipod:ipad");
+    // folders by default if annotation is not found
+    // possiblename1:possiblename2: ......
+    // if no folders found the last found will be the default
+    define('KOLAB_DEFAULTFOLDER_DIARY',"calendar:kalender:calendrier:agenda");
+    define('KOLAB_DEFAULTFOLDER_CONTACT',"contacts:kontact");
+    define('KOLAB_DEFAULTFOLDER_TASK',"task:taske");
+    // If 1: shared folders will be read-only, even if the user have rights on it
+    define('KOLAB_SHAREDFOLDERS_RO',"1");
+
+    // Logfile
+    define('KOLAB_LOGFILE',"/var/log/z-push/access.log");
+     //For Gal
+    define('SYNC_GAL_DISPLAYNAME','cn');
+    define('SYNC_GAL_PHONE','telephonenumber');
+    define('SYNC_GAL_OFFICE', '');
+    define('SYNC_GAL_TITLE','title');
+    define('SYNC_GAL_COMPANY','o');
+    define('SYNC_GAL_ALIAS','uid');
+    define('SYNC_GAL_FIRSTNAME','givenname');
+    define('SYNC_GAL_LASTNAME','sn');
+    define('SYNC_GAL_HOMEPHONE','homephone');
+    define('SYNC_GAL_MOBILEPHONE','mobile');
+    define('SYNC_GAL_EMAILADDRESS','mail');
+
+?>


commit fa8610f4ac59b448cc5516a6eedc2386cddcff08
Author: Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen at kolabsys.com>
Date:   Sat May 5 02:04:23 2012 +0100

    Ship extra setup routines
    Ship extra template files

diff --git a/pykolab/Makefile.am b/pykolab/Makefile.am
index b4758b6..4ce35ac 100644
--- a/pykolab/Makefile.am
+++ b/pykolab/Makefile.am
@@ -51,12 +51,14 @@ pykolab_plugins_recipientpolicy_PYTHON = \
 pykolab_setupdir = $(pythondir)/$(PACKAGE)/setup
 pykolab_setup_PYTHON = \
 	setup/components.py \
+	setup/setup_freebusy.py \
 	setup/setup_imap.py \
 	setup/setup_kolabd.py \
 	setup/setup_ldap.py \
 	setup/setup_mta.py \
 	setup/setup_mysql.py \
 	setup/setup_roundcube.py \
+	setup/setup_zpush.py \
 	setup/__init__.py
 
 pykolab_testsdir = $(pythondir)/$(PACKAGE)/tests
diff --git a/share/Makefile.am b/share/Makefile.am
index 047b5c2..8a6dd94 100644
--- a/share/Makefile.am
+++ b/share/Makefile.am
@@ -3,16 +3,28 @@ templatedir = $(datadir)/kolab/templates
 template_DATA = \
 	$(wildcard templates/*.tpl)
 
+hordetemplatedir = $(datadir)/kolab/templates/horde/conf.d/
+hordetemplate_DATA = \
+	$(wildcard templates/horde/conf.d/*.tpl)
+
 rctemplatedir = $(datadir)/kolab/templates/roundcubemail
 rctemplate_DATA = \
 	$(wildcard templates/roundcubemail/*.tpl)
 
+zpushtemplatedir = $(datadir)/kolab/templates/zpush
+zpushtemplate_DATA = \
+	$(wildcard templates/zpush/*.tpl)
+
 EXTRA_DIST = \
 	$(template_DATA) \
-	$(rctemplate_DATA)
+	$(hordetemplate_DATA) \
+	$(rctemplate_DATA) \
+	$(zpushtemplate_DATA)
 
 install-exec-local:
 	mkdir -p \
 		$(DESTDIR)/$(sysconfdir)/kolab/templates \
-		$(DESTDIR)/$(sysconfdir)/kolab/templates/roundcubemail
+		$(DESTDIR)/$(sysconfdir)/kolab/templates/horde/conf.d \
+		$(DESTDIR)/$(sysconfdir)/kolab/templates/roundcubemail \
+		$(DESTDIR)/$(sysconfdir)/kolab/templates/zpush
 


commit be0ef5a68ffc3ece17acb0a6a3df281375789040
Author: Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen at kolabsys.com>
Date:   Sat May 5 02:03:46 2012 +0100

    Add the submission service to postfix/master.cf.tpl

diff --git a/share/templates/master.cf.tpl b/share/templates/master.cf.tpl
index 8a94637..139313e 100644
--- a/share/templates/master.cf.tpl
+++ b/share/templates/master.cf.tpl
@@ -13,12 +13,16 @@ smtp      inet  n       -       n       -       -       smtpd
 #smtpd     pass  -       -       n       -       -       smtpd
 #dnsblog   unix  -       -       n       -       0       dnsblog
 #tlsproxy  unix  -       -       n       -       0       tlsproxy
-#submission inet n       -       n       -       -       smtpd
-#  -o syslog_name=postfix/submission
-#  -o smtpd_tls_security_level=encrypt
-#  -o smtpd_sasl_auth_enable=yes
-#  -o smtpd_client_restrictions=permit_sasl_authenticated,reject
-#  -o milter_macro_daemon_name=ORIGINATING
+submission inet n       -       n       -       -       smtpd
+    -o syslog_name=postfix/submission
+    -o smtpd_tls_security_level=encrypt
+    -o smtpd_sasl_auth_enable=yes
+    -o smtpd_sasl_authenticated_header=yes
+    -o smtpd_client_restrictions=permit_sasl_authenticated,reject
+    -o smtpd_data_restrictions=$submission_data_restrictions
+    -o smtpd_recipient_restrictions=$submission_recipient_restrictions
+    -o smtpd_sender_restrictions=$submission_sender_restrictions
+
 #smtps     inet  n       -       n       -       -       smtpd
 #  -o syslog_name=postfix/smtps
 #  -o smtpd_tls_wrappermode=yes


commit b73cc1c23ac6e40ac9883b476bb3f69739120342
Author: Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen at kolabsys.com>
Date:   Sat May 5 02:03:24 2012 +0100

    Add basic kolab configuration template

diff --git a/share/templates/horde/conf.d/10-kolab_conf_base.php.tpl b/share/templates/horde/conf.d/10-kolab_conf_base.php.tpl
new file mode 100644
index 0000000..0b48ced
--- /dev/null
+++ b/share/templates/horde/conf.d/10-kolab_conf_base.php.tpl
@@ -0,0 +1,66 @@
+<?php
+
+\$conf['debug_level'] = E_ALL;
+
+\$conf['tmpdir'] = '/var/lib/horde/tmp/';
+
+\$conf['sql']['phptype'] = 'mysql';
+\$conf['sql']['persistent'] = true;
+\$conf['sql']['protocol'] = 'tcp';
+\$conf['sql']['hostspec'] = 'localhost';
+\$conf['sql']['username'] = 'roundcube';
+\$conf['sql']['password'] = '$roundcube_mysql_password';
+\$conf['sql']['database'] = 'roundcube';
+\$conf['sql']['charset'] = 'utf-8';
+
+\$conf['auth']['driver'] = 'kolab';
+\$conf['auth']['params']['login_block'] = false;
+
+\$conf['log']['priority'] = PEAR_LOG_DEBUG;
+\$conf['log']['ident'] = 'HORDE';
+\$conf['log']['params'] = array();
+\$conf['log']['name'] = '/var/log/horde/horde.log';
+\$conf['log']['params']['append'] = true;
+\$conf['log']['type'] = 'file';
+\$conf['log']['enabled'] = true;
+
+\$conf['alarms']['driver'] = 'sql';
+\$conf['prefs']['driver'] = 'sql';
+\$conf['token']['driver'] = 'sql';
+\$conf['vfs']['type'] = 'musql';
+
+\$conf['perms']['driver'] = 'sql';
+
+\$conf['group']['driver'] = 'kolab';
+\$conf['group']['cache'] = true;
+\$conf['share']['cache'] = true;
+\$conf['share']['driver'] = 'kolab';
+
+\$conf['cache']['default_lifetime'] = 1800;
+\$conf['cache']['driver'] = 'memcache';
+
+\$conf['mailer']['params']['host'] = 'localhost';
+\$conf['mailer']['params']['port'] = 587;
+\$conf['mailer']['params']['auth'] = true;
+\$conf['mailer']['type'] = 'smtp';
+
+\$conf['accounts']['driver'] = 'kolab';
+\$conf['accounts']['params']['attr'] = 'mail';
+\$conf['accounts']['params']['strip'] = false;
+
+\$conf['kolab']['ldap']['server'] = 'localhost';
+\$conf['kolab']['ldap']['basedn'] = '$ldap_base_dn';
+\$conf['kolab']['ldap']['port'] = 389;
+\$conf['kolab']['imap']['maildomain'] = '$primary_domain';
+\$conf['kolab']['imap']['server'] = 'localhost';
+\$conf['kolab']['imap']['port'] = 143;
+\$conf['kolab']['imap']['protocol'] = "imap/tls/novalidate-cert";
+\$conf['kolab']['imap']['sieveport'] = 4190;
+\$conf['kolab']['imap']['cache_folders'] = true;
+\$conf['kolab']['smtp']['server'] = 'localhost';
+\$conf['kolab']['smtp']['port'] = 587;
+\$conf['kolab']['misc']['multidomain'] = false;
+\$conf['kolab']['cache_folders'] = true;
+\$conf['kolab']['enabled'] = true;
+\$conf['kolab']['freebusy']['server'] = 'https://' . \$_SERVER["HTTP_HOST"] . '/freebusy';
+


commit fbdb316b766747004dc7f17a9dab1098211105ab
Author: Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen at kolabsys.com>
Date:   Sat May 5 02:03:09 2012 +0100

    Store the mysql password for user roundcube in conf

diff --git a/pykolab/setup/setup_roundcube.py b/pykolab/setup/setup_roundcube.py
index 88965f2..75c400e 100644
--- a/pykolab/setup/setup_roundcube.py
+++ b/pykolab/setup/setup_roundcube.py
@@ -46,6 +46,8 @@ def execute(*args, **kw):
             password=True
         )
 
+    conf.mysql_roundcube_password = mysql_roundcube_password
+
     rc_settings = {
             'imap_admin_login': conf.get('cyrus-imapd', 'admin_login'),
             'imap_admin_password': conf.get('cyrus-imapd', 'admin_password'),


commit 9090cfaf49bb7bd73ef8a54c90e7607338749ab4
Author: Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen at kolabsys.com>
Date:   Fri May 4 18:26:16 2012 +0100

    Set correct certificate paths to a freshly generated dummy certificate

diff --git a/pykolab/setup/setup_mta.py b/pykolab/setup/setup_mta.py
index 1cb35a6..ae80c3e 100644
--- a/pykolab/setup/setup_mta.py
+++ b/pykolab/setup/setup_mta.py
@@ -192,9 +192,9 @@ result_attribute = mail
             "mydestination": "ldap:/etc/postfix/ldap/mydestination.cf",
             "transport_maps": "ldap:/etc/postfix/ldap/transport_maps.cf",
             "virtual_alias_maps": "$alias_maps, ldap:/etc/postfix/ldap/virtual_alias_maps.cf, ldap:/etc/postfix/ldap/mailenabled_distgroups.cf, ldap:/etc/postfix/ldap/mailenabled_dynamic_distgroups.cf",
-            "smtpd_tls_auth_only": "no",
-            "smtpd_tls_cert_file": "/etc/pki/tls/certs/localhost.crt",
-            "smtpd_tls_key_file": "/etc/pki/tls/private/localhost.key",
+            "smtpd_tls_auth_only": "yes",
+            "smtpd_tls_cert_file": "/etc/pki/tls/private/localhost.pem",
+            "smtpd_tls_key_file": "/etc/pki/tls/private/localhost.pem",
             "smtpd_recipient_restrictions": "permit_mynetworks, reject_unauth_pipelining, reject_rbl_client zen.spamhaus.org, reject_non_fqdn_recipient, reject_invalid_helo_hostname, reject_unknown_recipient_domain, reject_unauth_destination, check_policy_service unix:private/recipient_policy_incoming, permit",
             "smtpd_sender_restrictions": "permit_mynetworks, check_policy_service unix:private/sender_policy_incoming",
             "submission_recipient_restrictions": "check_policy_service unix:private/submission_policy, permit_sasl_authenticated, reject",
@@ -248,5 +248,7 @@ result_attribute = mail
         log.error(_("Could not write out Postfix configuration file /etc/postfix/master.cf"))
         return
 
+    subprocess.call(['/etc/pki/tls/certs/make-dummy-cert', '/etc/pki/tls/private/localhost.pem'])
+
     subprocess.call(['service', 'postfix', 'restart'])
 


commit eb0e0cb4e81d5daf9f2d78fcc02ce2d788164acd
Author: Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen at kolabsys.com>
Date:   Fri May 4 18:19:08 2012 +0100

    Fix another typo

diff --git a/pykolab/setup/setup_mta.py b/pykolab/setup/setup_mta.py
index 0a9a810..1cb35a6 100644
--- a/pykolab/setup/setup_mta.py
+++ b/pykolab/setup/setup_mta.py
@@ -50,7 +50,7 @@ def execute(*args, **kw):
         user_filter = conf.get('ldap','user_filter')
 
     files = {
-            "/etc/postfix/ldap/local_recipients_maps.cf": """
+            "/etc/postfix/ldap/local_recipient_maps.cf": """
 server_host = localhost
 server_port = 389
 version = 3


commit 844c99635e5f449e44cf51f7ef2e8595cb3132f5
Author: Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen at kolabsys.com>
Date:   Fri May 4 16:46:47 2012 +0100

    Bump pre-release

diff --git a/configure.ac b/configure.ac
index 3820037..7179101 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1,5 +1,5 @@
 AC_INIT([pykolab], 0.4)
-AC_SUBST([RELEASE], 0.9)
+AC_SUBST([RELEASE], 0.10)
 
 AC_CONFIG_SRCDIR(pykolab/constants.py.in)
 


commit 410bf5dca72d3079c276d3dd9b6a017e5dcbd972
Author: Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen at kolabsys.com>
Date:   Fri May 4 16:46:33 2012 +0100

    Lint issue

diff --git a/pykolab/auth/ldap/__init__.py b/pykolab/auth/ldap/__init__.py
index d814aae..2f01ba3 100644
--- a/pykolab/auth/ldap/__init__.py
+++ b/pykolab/auth/ldap/__init__.py
@@ -455,7 +455,9 @@ class LDAP(pykolab.base.Base):
 
         # Primary mail address
         if not primary_mail == None:
-            if not entry.has_key(primary_mail_attribute) or entry[primary_mail_attribute] == None:
+            if not entry.has_key(primary_mail_attribute) or \
+                    entry[primary_mail_attribute] == None:
+
                 primary_mail_address = conf.plugins.exec_hook(
                         "set_primary_mail",
                         kw={


commit ce08efd8fe57d7a8b359f26b265c0a1891c71f31
Author: Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen at kolabsys.com>
Date:   Fri May 4 16:35:46 2012 +0100

    Disable plugin terms by default

diff --git a/share/templates/roundcubemail/main.inc.php.tpl b/share/templates/roundcubemail/main.inc.php.tpl
index 505e768..2828c9b 100644
--- a/share/templates/roundcubemail/main.inc.php.tpl
+++ b/share/templates/roundcubemail/main.inc.php.tpl
@@ -109,7 +109,6 @@
     //        'quickrules',
 
             'redundant_attachments',
-            'terms',
             'threading_as_default',
             // contextmenu must be after kolab_addressbook (#444)
             'contextmenu',
@@ -189,7 +188,6 @@
             'kolab_config',
             'kolab_folders',
             'password',
-            'terms'
         );
 
     foreach ( \$mandatory_plugins as \$num => \$plugin ) {


commit 31c00e8ab2c9252c05d655fa3430b6692919a595
Author: Jeroen van Meeuwen (Kolab Systems) <vanmeeuwen at kolabsys.com>
Date:   Fri May 4 16:30:37 2012 +0100

    Add horde_cache to sql schema files,
    prevent duplicates

diff --git a/pykolab/setup/setup_roundcube.py b/pykolab/setup/setup_roundcube.py
index a5ce45c..88965f2 100644
--- a/pykolab/setup/setup_roundcube.py
+++ b/pykolab/setup/setup_roundcube.py
@@ -110,12 +110,21 @@ def execute(*args, **kw):
     for root, directories, filenames in os.walk('/usr/share/doc/'):
         for filename in filenames:
             if filename.startswith('mysql.initial') and filename.endswith('.sql'):
-                schema_files.append(os.path.join(root,filename))
+                schema_filepath = os.path.join(root,filename)
+                if not schema_filepath in schema_files:
+                    schema_files.append(schema_filepath)
+
+            if filename.startswith('horde_cache') and filename.endswith('.sql'):
+                schema_filepath = os.path.join(root,filename)
+                if not schema_filepath in schema_files:
+                    schema_files.append(schema_filepath)
 
     for root, directories, filenames in os.walk('/usr/share/roundcubemail/plugins/calendar/drivers/kolab/'):
         for filename in filenames:
             if filename.startswith('mysql') and filename.endswith('.sql'):
-                schema_files.append(os.path.join(root,filename))
+                schema_filepath = os.path.join(root,filename)
+                if not schema_filepath in schema_files:
+                    schema_files.append(schema_filepath)
 
     p1 = subprocess.Popen(['echo', 'create database roundcube;'], stdout=subprocess.PIPE)
     p2 = subprocess.Popen(['mysql', '--defaults-file=/tmp/kolab-setup-my.cnf'], stdin=p1.stdout)





More information about the commits mailing list