diff options
author | lebarjack <francois.perichon@univ-lille2.fr> | 2008-06-23 11:57:07 +0000 |
---|---|---|
committer | lebarjack <francois.perichon@univ-lille2.fr> | 2008-06-23 11:57:07 +0000 |
commit | 869eeb3f72862dd4cd2b0d9f23e585a441c3ce38 (patch) | |
tree | 8b487689a0924965bc1b1940717fc0c30d8fc2e2 /www-apps/davical | |
parent | media-tv/em28xx-new: Revert revision #6351, cd ${S} is really needed (diff) | |
download | sunrise-869eeb3f72862dd4cd2b0d9f23e585a441c3ce38.tar.gz sunrise-869eeb3f72862dd4cd2b0d9f23e585a441c3ce38.tar.bz2 sunrise-869eeb3f72862dd4cd2b0d9f23e585a441c3ce38.zip |
www-apps/davical: New ebuild for bug 195118 - (initial work by Cory Coager <ccoager@gmail.com>)
svn path=/sunrise/; revision=6356
Diffstat (limited to 'www-apps/davical')
-rw-r--r-- | www-apps/davical/ChangeLog | 9 | ||||
-rw-r--r-- | www-apps/davical/Manifest | 7 | ||||
-rw-r--r-- | www-apps/davical/davical-0.9.5.ebuild | 77 | ||||
-rw-r--r-- | www-apps/davical/files/driver_ldap.patch | 12 | ||||
-rw-r--r-- | www-apps/davical/files/postinstall-en-0.9.5.txt | 27 | ||||
-rw-r--r-- | www-apps/davical/files/rscds.conf | 279 | ||||
-rw-r--r-- | www-apps/davical/metadata.xml | 5 |
7 files changed, 416 insertions, 0 deletions
diff --git a/www-apps/davical/ChangeLog b/www-apps/davical/ChangeLog new file mode 100644 index 000000000..382b3a02f --- /dev/null +++ b/www-apps/davical/ChangeLog @@ -0,0 +1,9 @@ +# ChangeLog for www-apps/davical +# Copyright 1999-2008 Gentoo Foundation; Distributed under the GPL v2 +# $Header: $ + + 23 Jun 2008; lebarjack <francois.perichon@univ-lille2.fr> + +davical-0.9.5.ebuild, +files/postinstall-en-0.9.5.txt, + +files/driver_ldap.patch, +files/rscds.conf, +metadata.xml: + New ebuild for bug 195118 - (initial work by Cory Coager <ccoager@gmail.com>) + diff --git a/www-apps/davical/Manifest b/www-apps/davical/Manifest new file mode 100644 index 000000000..e69c5c2a4 --- /dev/null +++ b/www-apps/davical/Manifest @@ -0,0 +1,7 @@ +AUX driver_ldap.patch 993 RMD160 94a1ab8ac1ecea422d9e0e9a482c1512f0637339 SHA1 82d4764003094a63a1203a0cb795cf7967a55387 SHA256 c5091d5ba48f6f963af3ed0735a31e96a7d9c624668e3992275cdc3de1383984 +AUX postinstall-en-0.9.5.txt 1014 RMD160 8d20edeefbc627bae1d025be057d629530821036 SHA1 7e6c71d17334834924cde3fd234f3bca61073469 SHA256 01c922524a1bd81b7f060fa58d4a0b8766587e1d93c6a6d6452306daaf5abce5 +AUX rscds.conf 11907 RMD160 bdd38b174cf76e2a2ea76da5ed09706d000ccd20 SHA1 12da666505dd8fb814e775f21f9bc7e623dc7597 SHA256 25d27389f72caf07e9c008bd1cfe791eac69a85309ab226946d9d7e4304ec9b7 +DIST rscds-0.9.5.tar.gz 657693 RMD160 a2129e6387153be1ae871547952efb8739d1eb16 SHA1 2343864d14ca193b166a6124a523e1b0ff4c99f3 SHA256 202f4167926646ee1bba9128817011835ee29fc33445d41ee5103d357de662db +EBUILD davical-0.9.5.ebuild 1710 RMD160 6a369e159be5e284d746b53a9aa6351249cb3d6b SHA1 ec53386d8a323a9c1f3b34f860674231602e6a9a SHA256 be945e525875fa0787eb2959c4ba62eac558f6c899590d4aa87c4ec6592a61f4 +MISC ChangeLog 378 RMD160 7de401c585040e5cce403b44151af44673a0d712 SHA1 67c0652579f86a1ebc03660ba88700773fb90678 SHA256 c5ceee0d35768104bbf515e9fb5d0b7032e31a6231dddd2a2d1267a15bba21b3 +MISC metadata.xml 170 RMD160 645927a396fdc21cdeb089fe42c5397332420ea6 SHA1 ac7f48a14fec325926f9ce1be8fbf1f311b4f2e4 SHA256 d797a2ec6f9dc516c9f9c1a758ee87ad3e8c43101b5dc76c2f872d5bd4639b42 diff --git a/www-apps/davical/davical-0.9.5.ebuild b/www-apps/davical/davical-0.9.5.ebuild new file mode 100644 index 000000000..0d0918942 --- /dev/null +++ b/www-apps/davical/davical-0.9.5.ebuild @@ -0,0 +1,77 @@ +# Copyright 1999-2008 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: $ + +inherit eutils webapp depend.php versionator + +DESCRIPTION="A CalDAV and iCal server" +HOMEPAGE="http://rscds.sourceforge.net/" +SRC_URI="mirror://sourceforge/rscds/rscds-${PV}.tar.gz" + +LICENSE="GPL-2" +KEYWORDS="~amd64 ~x86" +IUSE="doc vhosts" +DEPEND="doc? ( dev-php/PEAR-PhpDocumentor )" +RDEPEND="www-servers/apache + dev-lang/php + app-admin/pwgen + dev-php/libawl-php + dev-perl/yaml + dev-perl/DBI + dev-perl/DBD-Pg" + +S="${WORKDIR}/rscds-${PV}" + +need_php5 +need_httpd + +pkg_setup() { + webapp_pkg_setup + require_php_with_use pcre postgres xml +} + +src_unpack() { + unpack ${A} + cd "${S}" + epatch "${FILESDIR}/driver_ldap.patch" +} + +src_compile() { + if use doc ; then + ebegin "Generating documentation" + phpdoc -c "docs/api/phpdoc.ini" + eend $? || die "Documentation failed to build" + fi + emake inc/always.php + scripts/po/rebuild-translations.sh +} + +src_install() { + webapp_src_preinst + + local docs="INSTALL README debian/README.debian \ + testing/README.regression_tests \ + TODO debian/changelog" + dodoc-php ${docs} || die "dodoc failed" + + einfo "Installing main files" + local dirs="htdocs inc locale" + insinto "${MY_HTDOCSDIR}" + doins -r ${dirs} || die "doins failed" + + einfo "Installing sql files" + insinto "${MY_SQLSCRIPTSDIR}" + doins -r dba/* || die "doins failed" + + if use doc ; then + einfo "Installing documentation" + dohtml -r "docs/api/" || die "dohtml failed" + dohtml -r "docs/website/" || die "dohtml failed" + fi + + insinto /etc/davical/ + newins "${FILESDIR}/rscds.conf" calendar.example.com-conf.php + + webapp_postinst_txt en "${FILESDIR}/postinstall-en-${PV}.txt" + webapp_src_install +} diff --git a/www-apps/davical/files/driver_ldap.patch b/www-apps/davical/files/driver_ldap.patch new file mode 100644 index 000000000..d2683ac3d --- /dev/null +++ b/www-apps/davical/files/driver_ldap.patch @@ -0,0 +1,12 @@ +diff -urN rscds-0.9.5.orig/inc/drivers_ldap.php rscds-0.9.5/inc/drivers_ldap.php +--- rscds-0.9.5.orig/inc/drivers_ldap.php 2008-06-20 09:55:09.000000000 +0200 ++++ rscds-0.9.5/inc/drivers_ldap.php 2008-06-20 09:56:42.000000000 +0200 +@@ -105,7 +105,7 @@ + if (!ldap_bind($this->connect,$config['bindDN'],$config['passDN'])){ + $bindDN = isset($config['bindDN']) ? $config['bindDN'] : 'anonymous'; + $passDN = isset($config['passDN']) ? $config['passDN'] : 'anonymous'; +- dbg_error_log( "LDAP", i18n('drivers_ldap : Failed to bind to host %1$s on port %2$s with bindDN of %3$s'), $host, $port $bindDN ); ++ dbg_error_log( "LDAP", i18n('drivers_ldap : Failed to bind to host %1$s on port %2$s with bindDN of %3$s'), $host, $port, $bindDN ); + $c->messages[] = i18n( 'drivers_ldap : Unable to bind to LDAP - check your configuration for bindDN and passDN, and that your LDAP server is reachable'); + $this->valid=false; + return ; diff --git a/www-apps/davical/files/postinstall-en-0.9.5.txt b/www-apps/davical/files/postinstall-en-0.9.5.txt new file mode 100644 index 000000000..0565bf1c2 --- /dev/null +++ b/www-apps/davical/files/postinstall-en-0.9.5.txt @@ -0,0 +1,27 @@ +1. You must setup a configuration file in the follow location: + /etc/davical/<servername>-conf.php + +2. Apache must be configured, here is a template: + <VirtualHost *:80> + DocumentRoot /var/www/<vhost>/htdocs/rscds/htdocs + DirectoryIndex index.php index.html + ServerName calendar.example.com + ServerAlias calendar.example.com + Alias /images/ /var/www/<vhost>/htdocs/images/ + php_value include_path /usr/share/awl/inc + php_value magic_quotes_gpc 0 + php_value register_globals 0 + <Directory "/var/www/<vhost>/htdocs/rscds/htdocs"> + Order deny,allow + Allow from all + </Directory> + </VirtualHost> + +3. You must setup a database in PostGreSQL. Follow these instructions: + su postgres -c createuser --no-createdb general + su postgres -c \ + /usr/share/webapps/rscds/<version>/sqlscripts/create-database.sh + + +The full installation documentation can be found here: + http://rscds.sourceforge.net/installation.php diff --git a/www-apps/davical/files/rscds.conf b/www-apps/davical/files/rscds.conf new file mode 100644 index 000000000..0288764bb --- /dev/null +++ b/www-apps/davical/files/rscds.conf @@ -0,0 +1,279 @@ +<?php +/*************************************************************************** +* * +* These apply everywhere and will need setting * +* * +***************************************************************************/ + +/**************************** +********* Mandatory ********* +*****************************/ + +/** +* Ex : $c->pg_connect[] = 'dbname=davical port=5432 user=general' +* The application will attempt to +* connect to the database, successively applying connection parameters from +* the array in $c->pg_connect. +* used in the web interface but also the caldav Server +*/ +$c->pg_connect[] = "dbname=davical user=general"; +// $c->pg_connect[] = "dbname=davical user=general port=5433 host=somehost password=mypass"; + + +/**************************** +********* Desirable ********* +*****************************/ + +/** +* default : Really Simple CalDAV Store +* Is used to specify the authentication realm of the server, as well as +* being used as a name to display in various places. +*/ +$c->system_name = "Really Simple CalDAV Store"; + +/** +* default is false +* If true, then events requested from someone other than the admmin or owner +* of a calendar will not get any alarm for it. Some client software also +* allows you to configure calendar by calendar which ones allow alarms. +*/ +$c->hide_alarm = true; + +/** +*default is false +*If true, then TODO requested from someone other than the admmin or owner +* of a calendar will not get any answer +*/ +$c->hide_TODO = true; + +/*************************************************************************** +* * +* ADMIN web Interface * +* * +***************************************************************************/ +/** +* Displayed on the login page to indicate who you should ask if you have +* problems logging on. Also for the "From" of the email sent when a user +* has lost his password and click on the login page +* on "Help! I've forgotten my password" +*/ +$c->admin_email ='calendar-admin@example.com'; + +/** +* default=true +* if true the admin web interface will +* have link on name to access details +* <p>The "enable_row_linking" option controls whether javascript is used +* to make the entire row clickable in browse lists in the administration +* pages. Since this doesn't work in Konqueror you may want to set this +* to false if you expect people to be using Konqueror with the DAViCal +* administration pages.</p> +*/ +// $c->enable_row_linking = true; + +/** +* These should be an array of style sheets with a path specified relative +* to the root directory. Used for overriding display styles in the admin +* interface. +* e.g. : $c->local_styles = array('/css/my.css'); +**/ +// $c->local_styles = array(); +// $c->print_styles = array(); + + +/*************************************************************************** +* * +* Caldav Server * +* * +***************************************************************************/ + +/** +* The "collections_always_exist" value defines whether a MKCALENDAR +* command is needed to create a calendar collection before calendar +* resources can be stored in it. You will want to leave this to the +* default (true) if people will be using Evolution or Sunbird / +* Lightning against this because that software does not support the +* creation of calendar collections. +* Default: true +*/ +// $c->collections_always_exist = true; + +/** +* The name of a user's "home" calendar. This will be created for each +* new user. +* Default: 'home' +*/ +// $c->home_calendar_name = 'home'; + +/** +* An array of groups / permissions which should be automatically added +* for each new user created. This is a crude mechanism which we +* will hopefully manage to work out some better approach for in the +* future. For now, create an array that looks something like: +* array( 9 => 'R', 4 => 'A' ) +* to create a 'read' relationship to user_no 9 and an 'all' relation +* with user_no 4. +* Default: none +*/ +// $c->default_relationships = array(); + + +/*************************************************************************** +* * +* External Authentication Sources * +* * +***************************************************************************/ + +/** +* Allow specifying another way to control access of the user by authenticating +* him against other drivers such has LDAP (the default is the PgSQL DB) +* $c->authenticate_hook['call'] should be set to the name of the plugin and must +* be a valid function that will be call like this: +* call_user_func( $c->authenticate_hook['call'], $username, $password ) +* +* The login mecanism is made in 2 places: +* - for the web interface in: index.php that calls RSCDSSession.php that extends +* Session.php (from AWL libraries) +* - for the caldav client in: caldav.php that calls BasicAuthSession.php +* Both Session.php and BasicAuthSession.php check against the +* authenticate_hook['call'], although for BasicAuthSession.php this will be for +* each page. For Session.php this will only occur during login. +* +* $c->authenticate_hook['config'] should be set up with any configuration data +* needed by the authenticate call for the moment used only in awl/inc/AuthPlugins.php +* and he used to authenticate the user should be at least 'password,user_no' +* awl/inc/AuthPlugins.php is a sample file not used by showing what could be +* a hook +*/ + +/********************************/ +/******* Other AWL hook *********/ +/********************************/ +// require_once('auth-functions.php'); +// $c->authenticate_hook = array( +// 'call' => 'AuthExternalAwl', +// 'config' => array( +// // A PgSQL database connection string for the database containing user records +// 'connection' => 'dbname=wrms host=otherhost port=5433 user=general', +// // Which columns should be fetched from the database +// 'columns' => "user_no, active, email_ok, joined, last_update AS updated, last_used, username, password, fullname, email", +// // a WHERE clause to limit the records returned. +// 'where' => "active AND org_code=7" +// ) +// ); + + +/********************************/ +/*********** LDAP hook **********/ +/********************************/ +/* + * For Active Directory go down to the next example. + */ + +//$c->authenticate_hook['call'] = 'LDAP_check'; +//$c->authenticate_hook['config'] = array( +// 'host' => 'www.tennaxia.net', //host name of your LDAP Server +// 'port' => '389', //port + + /* For the initial bind to be anonymous leave bindDN and passDN + commented out */ +// DN to bind to this server enabling to perform request +// 'bindDN'=> 'cn=manager,cn=internal,dc=tennaxia,dc=net', +// Password of the previous bindDN to bind to this server enabling to perform request +// 'passDN'=> 'xxxxxxxx', + +// 'protocolVersion' => '3', //Version of LDAP protocol to use +// 'baseDNUsers'=> 'dc=tennaxia,dc=net', //where to look at valid user +// 'filterUsers' => 'objectClass=kolabInetOrgPerson', //filter which must validate a user according to RFC4515, i.e. surrounded by brackets +// 'baseDNGroups' => 'ou=divisions,dc=tennaxia,dc=net', //not used ATM +// 'filterGroups' => 'objectClass=groupOfUniqueNames', //not used ATM + /** /!\ "username" should be set and "updated" must be set **/ +// 'mapping_field' => array("username" => "uid", +// "updated" => "modifyTimestamp", +// "fullname" => "cn" , +// "email" =>"mail" +// ), //used to create the user based on his ldap properties + /** used to set default value for all users, will be overcharged by ldap if defined also in mapping_field **/ +// 'default_value' => array("date_format_type" => "E","locale" => "fr_FR"), + /** foreach key set start and length in the string provided by ldap + example for openLDAP timestamp : 20070503162215Z **/ +// 'format_updated'=> array('Y' => array(0,4),'m' => array(4,2),'d'=> array(6,2),'H' => array(8,2),'M'=>array(10,2),'S' => array(12,2)), +// 'startTLS' => 'yes', // Require that TLS is used for LDAP? + // If ldap_start_tls is not working, it is probably + // because php wants to validate the server's + // certificate. Try adding "TLS_REQCERT never" to the + // ldap configuration file that php uses (e.g. /etc/ldap.conf + // or /etc/ldap/ldap.conf). Of course, this lessens security! +// 'scope' => 'subtree', // Search scope to use, defaults to subtree. +// // Allowed values: base, onelevel, subtree. +// +// ); +// +//include('drivers_ldap.php'); + +/* + * Use the following LDAP example if you are using Active Directory + * + * You will need to change host, passDN and DOMAIN in bindDN + * and baseDNUsers. + */ +//$c->authenticate_hook['call'] = 'LDAP_check'; +//$c->authenticate_hook['config'] = array( +// 'host' => 'ldap://ldap.example.net', +// 'bindDN' => 'auth@DOMAIN', +// 'passDN' => 'secret', +// 'baseDNUsers' => 'dc=DOMAIN,dc=local', +// 'protocolVersion' => 3, +// 'optReferrals' => 0, +// 'filterUsers' => '(&(objectcategory=person)(objectclass=user)(givenname=*))', +// 'mapping_field' => array("username" => "uid", +// "fullname" => "cn" , +// "email" => "mail"), +// 'default_value' => array("date_format_type" => "E","locale" => "en_NZ"), +// 'format_updated' => array('Y' => array(0,4),'m' => array(4,2),'d'=> array(6,2),'H' => array(8,2),'M'=>array(10,2),'S' => array(12,2)) +// ); +//include('drivers_ldap.php'); + + +/** +* Authentication against PAM using the Squid helper script. +*/ +//$c->authenticate_hook = array( +// 'call' => 'SQUID_PAM_check', +// 'config' => array( 'script' => '/usr/bin/pam_auth', 'email_base' => 'example.com' ); +// ); +//include('drivers_squid_pam.php'); + + +/** +* The default locale will be "en_NZ"; +* If you are in a non-English locale, you can set the default_locale +* configuration to one of the supported locales. +* +* Supported Locales (at present, see: "select * from supported_locales ;" for a full list) +* +* "de_DE", "en_NZ", "es_AR", "fr_FR", "nl_NL", "ru_RU" +* +* If you want locale support you probably know more about configuring it than me, but +* at this stage it should be noted that all translations are UTF-8, and pages are +* served as UTF-8, so you will need to ensure that the UTF-8 versions of these locales +* are supported on your system. +* +* People interested in providing new translations are directed to the Wiki: +* http://rscds.sourceforge.net/moin/TranslatingRscds +**/ +// $c->default_locale = "en_NZ"; + +/** +* Default will be $_SERVER['SERVER_NAME']; +* This is used to construct URLs which are passed in the answers to the client. You may +* want to force this to a specific domain in responses if your system is accessed by +* multiple names, otherwise you probably won't need to change it. +*/ +// $c->domain_name; + +/** +* Used as a fallback for the TZID of an event where one is not supplied as part +* of a VEVENT. The local (server) time zone will be used as a default. +*/ +// $c->local_tzid; diff --git a/www-apps/davical/metadata.xml b/www-apps/davical/metadata.xml new file mode 100644 index 000000000..7e3286984 --- /dev/null +++ b/www-apps/davical/metadata.xml @@ -0,0 +1,5 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> +<herd>maintainer-wanted</herd> +</pkgmetadata> |