From c13ea91400cd1d3ade0e5c266f382e3ddbb4bf6c Mon Sep 17 00:00:00 2001 From: root Date: Mon, 8 Aug 2016 17:00:26 +0200 Subject: [PATCH] saving uncommitted changes in /etc prior to emerge run --- init.d/stunnel | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/init.d/stunnel b/init.d/stunnel index 6ca77a3..e7eee32 100755 --- a/init.d/stunnel +++ b/init.d/stunnel @@ -1,8 +1,9 @@ -#!/sbin/runscript +#!/sbin/openrc-run # Copyright 1999-2014 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Id$ +extra_started_commands="reload" SERVICENAME=${SVCNAME#*.} SERVICENAME=${SERVICENAME:-stunnel} STUNNEL_CONFIGFILE=${STUNNEL_CONFIGFILE:-/etc/stunnel/${SERVICENAME}.conf} @@ -41,3 +42,10 @@ stop() { start-stop-daemon --stop --quiet --pidfile ${PIDFILE} eend $? "Failed to stop ${SVCNAME}" } + +reload() { + get_config || return 1 + ebegin "Reloading ${SVCNAME}" + start-stop-daemon --signal HUP --pidfile ${PIDFILE} --name stunnel + eend $? +} -- 2.39.5