Compare commits

...

No commits in common. "0.0.1" and "master" have entirely different histories.

23 changed files with 137 additions and 4 deletions

11
createlinks Normal file
View File

@ -0,0 +1,11 @@
#!/usr/bin/perl -w
use esmith::Build::CreateLinks qw(:all);
templates2events("/usr/share/sogosync/config.php", qw(webapps-update bootstrap-console-save email-update));
templates2events("/usr/share/sogosync/backend/searchldap/config.php", qw(webapps-update bootstrap-console-save email-update));
safe_symlink("/etc/e-smith/templates-default/template-begin-php", "root/etc/e-smith/templates/usr/share/sogosync/config.php/template-begin");
safe_symlink("/etc/e-smith/templates-default/template-end-php", "root/etc/e-smith/templates/usr/share/sogosync/config.php/template-end");
safe_symlink("/etc/e-smith/templates-default/template-begin-php", "root/etc/e-smith/templates/usr/share/sogosync/backend/searchldap/config.php/template-begin");
safe_symlink("/etc/e-smith/templates-default/template-end-php", "root/etc/e-smith/templates/usr/share/sogosync/backend/searchldap/config.php/template-end");

View File

@ -16,7 +16,8 @@ Alias /Microsoft-Server-ActiveSync /usr/share/sogosync/index.php
php_admin_flag register_globals off
php_admin_flag magic_quotes_runtime off
php_admin_flag short_open_tag on
php_admin_value open_basedir /usr/share/sogosync:/usr/share/awl/in
php_admin_value open_basedir /usr/share/sogosync:/usr/share/awl/inc:/var/lib/sogosync:/var/log/sogosync
php_admin_value include_path /usr/share/sogosync:/usr/share/sogosync/include:/usr/share/awl/inc
Order deny,allow
Deny from all
Allow from $allow

View File

@ -0,0 +1,4 @@
define("LDAP_HOST", "ldap://127.0.0.1/");
define("LDAP_PORT", "{$ldap{'TCPPort'} || '389';}");
define("ANONYMOUS_BIND", true);

View File

@ -0,0 +1,13 @@
{
use esmith::util;
my $c = esmith::ConfigDB->open_ro;
my $domain = $c->get('DomainName')->value;
my $basedn = esmith::util::ldapBase($domain);
$OUT .=<<"EOF";
define("LDAP_SEARCH_BASE", "ou=Users,$basedn");
define("LDAP_SEARCH_FILTER", "(|(cn=*SEARCHVALUE*)(mail=*SEARCHVALUE*))");
EOF
}

View File

@ -0,0 +1,14 @@
global $ldap_field_map;
$ldap_field_map = array(
SYNC_GAL_DISPLAYNAME => 'cn',
SYNC_GAL_PHONE => 'telephonenumber',
SYNC_GAL_OFFICE => 'l',
SYNC_GAL_TITLE => 'title',
SYNC_GAL_COMPANY => 'o',
SYNC_GAL_ALIAS => 'uid',
SYNC_GAL_FIRSTNAME => 'givenname',
SYNC_GAL_LASTNAME => 'sn',
SYNC_GAL_HOMEPHONE => 'extensionnumber',
SYNC_GAL_MOBILEPHONE => 'mobile',
SYNC_GAL_EMAILADDRESS => 'mail',
);

View File

@ -0,0 +1 @@
define('TIMEZONE', '{$TimeZone}');

View File

@ -0,0 +1,10 @@
define('BASE_PATH', dirname($_SERVER['SCRIPT_FILENAME']) . "/");
define('STATE_DIR', '/var/lib/sogosync/');
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/" . PATH_SEPARATOR .
"/usr/share/awl/inc");

View File

@ -0,0 +1,10 @@
define('SCRIPT_TIMEOUT', 0);
define('MAX_EMBEDDED_SIZE', 2097152);
define('PROVISIONING', true);
define('LOOSE_PROVISIONING', false);
define('SYNC_CONFLICT_DEFAULT', SYNC_CONFLICT_OVERWRITE_PIM);
define('SYNC_FILTERTIME_MAX', SYNC_FILTERTYPE_ALL);
define('PING_INTERVAL', 30);
define('SINK_FORCERECHECK', 300);
define('FILEAS_ORDER', SYNC_FILEAS_FIRSTLAST);
define('SYNC_MAX_ITEMS', 100);

View File

@ -0,0 +1,7 @@
define('LOGFILEDIR', '/var/log/sogosync/');
define('LOGFILE', LOGFILEDIR . 'sogosync.log');
define('LOGERRORFILE', LOGFILEDIR . 'error.log');
define('LOGLEVEL', LOGLEVEL_INFO);
define('LOGAUTHFAIL', false);
define('LOGUSERLEVEL', LOGLEVEL_DEVICEID);
$specialLogUsers = array();

View File

@ -0,0 +1 @@
define('BACKEND_PROVIDER', "BackendCombined");

View File

@ -0,0 +1 @@
define('MAPI_SERVER', 'file:///var/run/zarafa');

View File

@ -0,0 +1,8 @@
define('IMAP_SERVER', 'localhost');
define('IMAP_PORT', {$imap{'TCPPort'} || '143'});
define('IMAP_OPTIONS', '/notls/norsh');
define('IMAP_DEFAULTFROM', '');
define('IMAP_SENTFOLDER', '{$sogod{'SentFolder'} || 'Sent';}');
define('IMAP_INLINE_FORWARD', false);
define('IMAP_USE_IMAPMAIL', true);

View File

@ -0,0 +1,2 @@
define('MAILDIR_BASE', '/tmp');
define('MAILDIR_SUBDIR', 'Maildir');

View File

@ -0,0 +1 @@
define('VCARDDIR_DIR', '/home/%u/.kde/share/apps/kabc/stdvcf');

View File

@ -0,0 +1,3 @@
define('SEARCH_PROVIDER', 'BackendSearchLDAP');
define('SEARCH_WAIT', 10);
define('SEARCH_MAXRESULTS', 80);

View File

@ -0,0 +1,9 @@
define('CALDAV_SERVER', 'http://localhost:{$sogod{'TCPPort'}}');
define('CALDAV_PATH', '/SOGo/dav/%u/');
define('CALDAV_PERSONAL', 'personal');
define('CALDAV_URL', 'http://localhost:{$sogod{'TCPPort'}}/SOGo/dav/%u/');
{
my $ro = $sogosync{'ReadOnly'} || 'disabled';
$ro = ($ro =~ m/^yes|enabled|1$/) ? 'true':'false';
$OUT .= " define('CALDAV_READONLY', $ro);\n";
}

View File

@ -0,0 +1,7 @@
define('CARDDAV_PERSONAL', 'personal');
define('CARDDAV_URL', 'http://localhost:{$sogod{'TCPPort'}}/SOGo/dav/%u/Contacts/');
{
my $ro = $sogosync{'ReadOnly'} || 'disabled';
$ro = ($ro =~ m/^yes|enabled|1$/) ? 'true':'false';
$OUT .= " define('CARDDAV_READONLY', $ro);\n";
}

View File

@ -0,0 +1,2 @@
$additionalFolders = array(
);

View File

@ -1,6 +1,6 @@
Name: smeserver-sogosync
Version: 0.0.1
Release: 0.beta0%{?dist}
Version: 0.1.9
Release: 1%{?dist}
Summary: SME Server integration for sogosync
Group: Application/System
@ -8,6 +8,7 @@ License: GNU GPL v2
URL: https://github.com/xbgmsharp/sogosync
Source0: %{name}-%{version}.tar.gz
BuildRoot: %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)
BuildArch: noarch
BuildRequires: e-smith-devtools
Requires: smeserver-webapps-common
@ -22,6 +23,7 @@ based on Z-Push
%setup -q -n %{name}-%{version}
%build
perl ./createlinks
%install
rm -rf $RPM_BUILD_ROOT
@ -29,6 +31,7 @@ rm -rf $RPM_BUILD_ROOT
/bin/rm -f %{name}-%{version}-filelist
/sbin/e-smith/genfilelist $RPM_BUILD_ROOT \
> %{name}-%{version}-filelist
echo "%doc CHANGELOG.git" >> %{name}-%{version}-filelist
%files -f %{name}-%{version}-filelist
%defattr(-,root,root)
@ -38,5 +41,30 @@ rm -rf $RPM_BUILD_ROOT
rm -rf $RPM_BUILD_ROOT
%changelog
* Sat Mar 31 2012 Daniel Berteaud <daniel@firewall-services.com> 0.0.1-1
* Tue Oct 2 2012 Daniel Berteaud <daniel@firewall-services.com> 0.1.9-1
- Fix template path for apache
* Sat Sep 22 2012 Daniel Berteaud <daniel@firewall-services.com> 0.1.8-1
- update default config
* Sun Jun 10 2012 Daniel Berteaud <daniel@firewall-services.com> 0.1.7-1
- Define *_READONLY constant event when set to false
- Add missing template for additional folders
* Sun Jun 10 2012 Daniel Berteaud <daniel@firewall-services.com> 0.1.6-1
- Correction des templates
* Sat Jun 9 2012 Daniel Berteaud <daniel@firewall-services.com> 0.1.5-1
- Config change for Z-Push 2
* Mon May 14 2012 Daniel Berteaud <daniel@firewall-services.com> 0.1.3-1
- Add new caldav param in config.php
* Fri Apr 27 2012 Daniel Berteaud <daniel@firewall-services.com> 0.1.2-1
- Re add CALDAV_URL param
* Thu Apr 26 2012 Daniel Berteaud <daniel@firewall-services.com> 0.1.1-1
- Update config templates
* Sat Mar 31 2012 Daniel Berteaud <daniel@firewall-services.com> 0.1.0-1
- initial package