Mail archive
alpine-devel

Re: [alpine-devel] [PATCH] main/tinc: fixed init scripts

From: Natanael Copa <ncopa_at_alpinelinux.org>
Date: Mon, 9 Jun 2014 10:55:41 +0200

On Sat, 7 Jun 2014 10:21:07 +0000
Stuart Cardall <developer_at_it-offshore.co.uk> wrote:

> This patch fixes an init script bug which caused 'restart' to fail
> & which sometimes could only be cleared by a reboot (--localstatedir
> was set as /usr/var so the pid was never found).

ugh. good catch!

 
> I changed 'stop' to use the start-stop-daemon as in tinc 1.1pre10 there
> is no longer an option to --kill. Message for an already stopped daemon
> corrected.

Why are we not using start-stop-daemon for start?

Can we reuse the gentoo init.d scripts?

http://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo-x86/net-misc/tinc/files/tincd?revision=1.9
http://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo-x86/net-misc/tinc/files/tincd.lo?revision=1.5&view=markup


> For the same reason I also changed 'reload' to use kill -1 $pid.
> ---
> main/tinc/APKBUILD | 15 ++++++++-------
> main/tinc/tincd.initd | 7 ++++---
> main/tinc/tincd.lo.initd | 9 +++++----
> 3 files changed, 17 insertions(+), 14 deletions(-)
>
> diff --git a/main/tinc/APKBUILD b/main/tinc/APKBUILD
> index ff98ecc..97674b3 100644
> --- a/main/tinc/APKBUILD
> +++ b/main/tinc/APKBUILD
> _at_@ -1,7 +1,7 @@
> # Maintainer: Natanael Copa <ncopa_at_alpinelinux.org>
> pkgname=tinc
> pkgver=1.0.24
> -pkgrel=0
> +pkgrel=1
> pkgdesc="tinc is a Virtual Private Network (VPN) daemon"
> url="http://www.tinc-vpn.org/"
> arch="all"
> _at_@ -35,6 +35,7 @@ build() {
> --sysconfdir=/etc \
> --mandir=/usr/share/man \
> --infodir=/usr/share/info \
> + --localstatedir=/var \
> --enable-jumbograms \
> --enable-lzo \
> --enable-zlib \

I applied the patch due to the above hunk and copied new version of init.d from gentoo.

Thanks!

-nc



---
Unsubscribe:  alpine-devel+unsubscribe_at_lists.alpinelinux.org
Help:         alpine-devel+help_at_lists.alpinelinux.org
---
Received on Mon Jun 09 2014 - 10:55:41 UTC