diff options
author | Daniele Coli <danielsan.dani@gmail.com> | 2016-02-14 12:10:18 +0100 |
---|---|---|
committer | Timo Teräs <timo.teras@iki.fi> | 2016-02-22 14:20:26 +0000 |
commit | 0b87fe1b7d417dad80a48b3d7743c37cf47cb943 (patch) | |
tree | ebc38dbc63d661902d7a4a8068c7f09bd38407ed | |
parent | 2e88ee6aebf661b9ea221e5dd3e251535eaba6f6 (diff) | |
download | alpine_aports-0b87fe1b7d417dad80a48b3d7743c37cf47cb943.tar.bz2 alpine_aports-0b87fe1b7d417dad80a48b3d7743c37cf47cb943.tar.xz alpine_aports-0b87fe1b7d417dad80a48b3d7743c37cf47cb943.zip |
main/fetchmail: Added description to init.d script and moved configuration options to confd
Added description to init.d script in order to make it compliant
with rc-system and avoid annoying warning messages on syslog.
Moved configuration file path and startup options to confd file.
-rw-r--r-- | main/fetchmail/APKBUILD | 19 | ||||
-rw-r--r-- | main/fetchmail/fetchmail.confd | 5 | ||||
-rwxr-xr-x | main/fetchmail/fetchmail.initd | 10 |
3 files changed, 23 insertions, 11 deletions
diff --git a/main/fetchmail/APKBUILD b/main/fetchmail/APKBUILD index 935b2a27cd..bcec2817ab 100644 --- a/main/fetchmail/APKBUILD +++ b/main/fetchmail/APKBUILD | |||
@@ -2,7 +2,7 @@ | |||
2 | # Maintainer: Natanael Copa <ncopa@alpinelinux.org> | 2 | # Maintainer: Natanael Copa <ncopa@alpinelinux.org> |
3 | pkgname=fetchmail | 3 | pkgname=fetchmail |
4 | pkgver=6.3.26 | 4 | pkgver=6.3.26 |
5 | pkgrel=5 | 5 | pkgrel=6 |
6 | pkgdesc="A remote-mail retrieval and forwarding utility" | 6 | pkgdesc="A remote-mail retrieval and forwarding utility" |
7 | url="http://www.fetchmail.info/" | 7 | url="http://www.fetchmail.info/" |
8 | arch="all" | 8 | arch="all" |
@@ -13,8 +13,9 @@ pkggroups="fetchmail" | |||
13 | makedepends="openssl-dev python" | 13 | makedepends="openssl-dev python" |
14 | install="fetchmail.pre-install" | 14 | install="fetchmail.pre-install" |
15 | subpackages="$pkgname-doc fetchmailconf" | 15 | subpackages="$pkgname-doc fetchmailconf" |
16 | source="http://downloads.sourceforge.net/project/${pkgname}/branch_6.3/fetchmail-${pkgver}.tar.xz | 16 | source="http://downloads.sourceforge.net/project/${pkgname}/branch_6.3/${pkgname}-${pkgver}.tar.xz |
17 | fetchmail.initd" | 17 | $pkgname.initd |
18 | $pkgname.confd" | ||
18 | _builddir="$srcdir/$pkgname-$pkgver" | 19 | _builddir="$srcdir/$pkgname-$pkgver" |
19 | 20 | ||
20 | prepare() { | 21 | prepare() { |
@@ -41,7 +42,8 @@ build() { | |||
41 | package() { | 42 | package() { |
42 | cd "$_builddir" | 43 | cd "$_builddir" |
43 | make DESTDIR="$pkgdir" install | 44 | make DESTDIR="$pkgdir" install |
44 | install -Dm755 "$srcdir"/fetchmail.initd "$pkgdir"/etc/init.d/fetchmail | 45 | install -Dm755 "$srcdir"/$pkgname.initd "$pkgdir"/etc/init.d/$pkgname |
46 | install -Dm644 "$srcdir"/$pkgname.confd "$pkgdir"/etc/conf.d/$pkgname | ||
45 | install -o fetchmail -g fetchmail -d "$pkgdir"/var/lib/fetchmail \ | 47 | install -o fetchmail -g fetchmail -d "$pkgdir"/var/lib/fetchmail \ |
46 | "$pkgdir"/var/run/fetchmail | 48 | "$pkgdir"/var/run/fetchmail |
47 | } | 49 | } |
@@ -57,8 +59,11 @@ fetchmailconf() { | |||
57 | } | 59 | } |
58 | 60 | ||
59 | md5sums="61b66faad044afa26e142bb1791aa2b3 fetchmail-6.3.26.tar.xz | 61 | md5sums="61b66faad044afa26e142bb1791aa2b3 fetchmail-6.3.26.tar.xz |
60 | 6beab7b7731b3d321904e2a8ec948121 fetchmail.initd" | 62 | 482cbb5f67bedaeb3ed559f6671d3d3d fetchmail.initd |
63 | 0203136e64395c8411b01d75407d1adc fetchmail.confd" | ||
61 | sha256sums="79b4c54cdbaf02c1a9a691d9948fcb1a77a1591a813e904283a8b614b757e850 fetchmail-6.3.26.tar.xz | 64 | sha256sums="79b4c54cdbaf02c1a9a691d9948fcb1a77a1591a813e904283a8b614b757e850 fetchmail-6.3.26.tar.xz |
62 | c97185a8c1944574025b83ca4fc78f76330881d7e6ea209caf6962913ad66ffe fetchmail.initd" | 65 | ec00bbe1e2e8932c2fada56aea805cf537b775e804bac1d8794e07659291e9d5 fetchmail.initd |
66 | 6343137640a25b115f015f41640bb498a6ebba471caa9374718364616aef3f85 fetchmail.confd" | ||
63 | sha512sums="8e0a2484e60eaf6c0231e2599e10fec6d207fa1c0fa02ec99b3ef9aea00b6d87275434e79470a25f06e358cdd4a293f9c46a82dd128fe733a99c85144e6caa63 fetchmail-6.3.26.tar.xz | 67 | sha512sums="8e0a2484e60eaf6c0231e2599e10fec6d207fa1c0fa02ec99b3ef9aea00b6d87275434e79470a25f06e358cdd4a293f9c46a82dd128fe733a99c85144e6caa63 fetchmail-6.3.26.tar.xz |
64 | 83128465a2e2e0df4ddd589cc7644e63ce013dee36196aa757b839edd5ec36775fc48fedd8c88ad51a8bb882bbfa573fff69546bbca84718ac9c1b915f35ff0a fetchmail.initd" | 68 | 989127859c91eaec9bfa38dd873f141b0561cbe08d9ac4ab700abe612950fc4d61ec9670becf0d432a46c4d1558a2fd65f62f84e79cea9387ec1d377dacaecce fetchmail.initd |
69 | 6f031ec6bd4a3ae53cd04fbd8470f4d10bd46ca29cabffa634a6801aa2e7707169855fbc045ced3c9a69523e694511a3f076b611678143e49339c8ccac98074e fetchmail.confd" | ||
diff --git a/main/fetchmail/fetchmail.confd b/main/fetchmail/fetchmail.confd new file mode 100644 index 0000000000..baa1a4c2af --- /dev/null +++ b/main/fetchmail/fetchmail.confd | |||
@@ -0,0 +1,5 @@ | |||
1 | # /etc/conf.d/fetchmail: config file for /etc/init.d/fetchmail | ||
2 | |||
3 | # See the fetchmail(1) man page for possible options to put here. | ||
4 | CFGFILE="/etc/fetchmailrc" | ||
5 | FETCHMAIL_OPTS="-d ${polling_period:-300}" | ||
diff --git a/main/fetchmail/fetchmail.initd b/main/fetchmail/fetchmail.initd index 8fd5adf0ac..ad826ec850 100755 --- a/main/fetchmail/fetchmail.initd +++ b/main/fetchmail/fetchmail.initd | |||
@@ -1,5 +1,7 @@ | |||
1 | #!/sbin/openrc-run | 1 | #!/sbin/openrc-run |
2 | 2 | ||
3 | description="Remote mail retrieval and forwarding" | ||
4 | |||
3 | pidfile=/var/run/fetchmail/fetchmail.pid | 5 | pidfile=/var/run/fetchmail/fetchmail.pid |
4 | 6 | ||
5 | depend() { | 7 | depend() { |
@@ -9,8 +11,8 @@ depend() { | |||
9 | } | 11 | } |
10 | 12 | ||
11 | checkconfig() { | 13 | checkconfig() { |
12 | if [ ! -f /etc/fetchmailrc ]; then | 14 | if [ ! -f "${CFGFILE}" ]; then |
13 | eerror "Configuration file /etc/fetchmailrc not found" | 15 | eerror "Configuration file ${CFGFILE} not found" |
14 | return 1 | 16 | return 1 |
15 | fi | 17 | fi |
16 | } | 18 | } |
@@ -22,8 +24,8 @@ start() { | |||
22 | ebegin "Starting fetchmail" | 24 | ebegin "Starting fetchmail" |
23 | start-stop-daemon --start --quiet \ | 25 | start-stop-daemon --start --quiet \ |
24 | --user fetchmail --exec /usr/bin/fetchmail \ | 26 | --user fetchmail --exec /usr/bin/fetchmail \ |
25 | -- -d ${polling_period:-300} -f /etc/fetchmailrc \ | 27 | --pidfile ${pidfile} -i /var/lib/fetchmail/.fetchids \ |
26 | --pidfile ${pidfile} -i /var/lib/fetchmail/.fetchids | 28 | -- -f "${CFGFILE}" ${FETCHMAIL_OPTS} |
27 | eend ${?} | 29 | eend ${?} |
28 | } | 30 | } |
29 | 31 | ||