From 8d739eb2a582466292cd85a1842bcc0609b4d5f6 Mon Sep 17 00:00:00 2001 From: Michael Mason Date: Thu, 5 Mar 2009 23:14:38 +0000 Subject: extra/dovecot Initial Commit --- extra/dovecot/APKBUILD | 34 ++++++++++++++++++++++++++++++++++ extra/dovecot/dovecot.initd | 41 +++++++++++++++++++++++++++++++++++++++++ extra/dovecot/dovecot.install | 11 +++++++++++ 3 files changed, 86 insertions(+) create mode 100644 extra/dovecot/APKBUILD create mode 100644 extra/dovecot/dovecot.initd create mode 100644 extra/dovecot/dovecot.install (limited to 'extra') diff --git a/extra/dovecot/APKBUILD b/extra/dovecot/APKBUILD new file mode 100644 index 00000000000..3db04221eaa --- /dev/null +++ b/extra/dovecot/APKBUILD @@ -0,0 +1,34 @@ +# Contributor: Michael Mason +# Maintainer: +pkgname=dovecot +pkgver=1.1.11 +pkgrel=0 +pkgdesc="IMAP and POP3 server" +url="http://www.dovecot.org/" +license="GPL" +depends="uclibc" +makedepends="" +install="dovecot.install" +subpackages="$pkgname-doc $pkgname-dev" +source="http://www.dovecot.org/releases/1.1/$pkgname-$pkgver.tar.gz + dovecot.initd + $install + " + +build() { + cd "$srcdir/$pkgname-$pkgver" + + ./configure --prefix=/usr \ + --sysconfdir=/etc \ + --mandir=/usr/share/man \ + --infodir=/usr/share/info \ + --with-pop3d + make || return 1 + make DESTDIR="$pkgdir" install + + # install -m755 -D "$srcdir"/$pkgname.initd "$pkgdir"/etc/init.d/$pkgname +} + +md5sums="c973eb41aca79fb16630a16f0d84f765 dovecot-1.1.11.tar.gz +ca3f9a2d8a75609b1edfa55f2709f598 dovecot.initd +766fcfe110ce0be9c416e669b08349b6 dovecot.install" diff --git a/extra/dovecot/dovecot.initd b/extra/dovecot/dovecot.initd new file mode 100644 index 00000000000..24201eeecb2 --- /dev/null +++ b/extra/dovecot/dovecot.initd @@ -0,0 +1,41 @@ +#!/sbin/runscript + +# Sample init.d file for alpine linux. + +NAME=dovecot +DAEMON=/usr/sbin/$NAME +USER=dovecot +group=dovecot + +depend() { + need net +} + +start() { + ebegin "Starting ${NAME}" + start-stop-daemon --start --quiet --background \ + --make-pidfile --pidfile /var/run/${NAME}.pid \ + --chuid ${USER}:${GROUP} \ + --exec ${DAEMON} -- ${OPTS} + eend $? +} + +stop() { + ebegin "Stopping ${NAME}" + start-stop-daemon --stop --quiet \ + --exec ${DAEMON} \ + --pidfile /var/run/${NAME}.pid \ + eend $? +} + +reload() { + ebegin "Reloading ${NAME}" + if ! service_started "${NAME}" ; then + eend 1 "${NAME} is not started" + return 1 + fi + start-stop-daemon --stop --oknodo --signal HUP \ + --exec ${DAEMON} --pidfile /var/run/${NAME}.pid + eend $? +} + diff --git a/extra/dovecot/dovecot.install b/extra/dovecot/dovecot.install new file mode 100644 index 00000000000..ab8a28762ab --- /dev/null +++ b/extra/dovecot/dovecot.install @@ -0,0 +1,11 @@ +#!/bin/sh + +case "$1" in + pre_install) + adduser -h /dev/null -s /bin/false -D dovecot 2>/dev/null + ;; + post_deinstall) + deluser dovecot + delgroup dovecot + ;; +esac -- cgit v1.2.3