diff options
Diffstat (limited to 'main/dovecot')
-rw-r--r-- | main/dovecot/APKBUILD | 7 | ||||
-rw-r--r-- | main/dovecot/dovecot.logrotate | 15 |
2 files changed, 21 insertions, 1 deletions
diff --git a/main/dovecot/APKBUILD b/main/dovecot/APKBUILD index dce739b802..c72d0bc396 100644 --- a/main/dovecot/APKBUILD +++ b/main/dovecot/APKBUILD @@ -2,19 +2,21 @@ # Maintainer: Natanael Copa <ncopa@alpinelinux.org> pkgname=dovecot pkgver=1.2.11 -pkgrel=4 +pkgrel=5 pkgdesc="IMAP and POP3 server" url="http://www.dovecot.org/" license="LGPL-2.1" depends="openssl" pkgusers="dovecot" pkggroups="dovecot" +depends="logrotate" makedepends="libcap-dev zlib-dev openssl-dev bzip2-dev postgresql-dev mysql-dev sqlite-dev" install="dovecot.pre-install dovecot.post-install" subpackages="$pkgname-doc $pkgname-dev $pkgname-pgsql $pkgname-mysql $pkgname-sqlite" source="http://www.dovecot.org/releases/1.2/$pkgname-$pkgver.tar.gz + dovecot.logrotate dovecot.initd " @@ -42,6 +44,7 @@ package() { install -d "$pkgdir"/var/run/dovecot \ "$pkgdir"/etc/ssl/dovecot install -m755 -D "$srcdir"/$pkgname.initd "$pkgdir"/etc/init.d/$pkgname + install -D "$srcdir"/dovecot.logrotate "$pkgdir"/etc/logrotate.d/dovecot install doc/dovecot-openssl.cnf "$pkgdir"/etc/dovecot/ mv "$pkgdir"/etc/dovecot/dovecot-example.conf \ "$pkgdir"/etc/dovecot/dovecot.conf || return 1 @@ -57,6 +60,7 @@ package() { s/\#passdb passwd/passdb passwd/ s/\#\}/\}/ }' \ + -e 's,#log_path =.*,log_path = /var/log/dovecot.log,' \ "$pkgdir"/etc/dovecot/dovecot.conf } @@ -87,4 +91,5 @@ sqlite() { } md5sums="bdac013fd57aa616ea4bdd9ac34557c6 dovecot-1.2.11.tar.gz +aec5cc797ab2acf72ce3b6bb1030345f dovecot.logrotate c58b474dca20e6e60fa4f1f5b9c726e1 dovecot.initd" diff --git a/main/dovecot/dovecot.logrotate b/main/dovecot/dovecot.logrotate new file mode 100644 index 0000000000..7bd0003f7f --- /dev/null +++ b/main/dovecot/dovecot.logrotate @@ -0,0 +1,15 @@ +/var/log/dovecot*.log { + daily + missingok + copytruncate + rotate 7 + compress + notifempty + sharedscripts + postrotate + if /etc/init.d/dovecot -q status ; then \ + /etc/init.d/dovecot reload > /dev/null 2>&1 || true ; \ + fi; + endscript +} + |