aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJakub Jirutka <jakub@jirutka.cz>2021-01-04 20:33:50 +0100
committerJakub Jirutka <jakub@jirutka.cz>2021-01-04 20:42:19 +0100
commit8ff923bf0b35048678e0c02847e04adbcf075726 (patch)
treefa7bf53dcf9d4b232a475b184a3532c95af5ec32
parentaa69c6aa2359c8adeb060aae9c37d7f21ee3e33a (diff)
downloadaports-8ff923bf0b35048678e0c02847e04adbcf075726.tar.gz
aports-8ff923bf0b35048678e0c02847e04adbcf075726.tar.bz2
aports-8ff923bf0b35048678e0c02847e04adbcf075726.tar.xz
main/freeradius: don't force supervise-daemon
Users can enable supervise-daemon simply by declaring `supervisor=supervise-daemon` in /etc/conf.d/radiusd. See my mail from Tue, 15 Dec 2020 15:33:16 +0100 in alpine-devel mailing-list in topic "Use of supervise-daemon in Alpine". (I cannot simply reference it from ML archive because it's broken.) This partially reverts 1a33da0225dc309c2e4c3d05a87093ab8fff7048.
-rw-r--r--main/freeradius/APKBUILD4
-rw-r--r--main/freeradius/radiusd.initd11
2 files changed, 11 insertions, 4 deletions
diff --git a/main/freeradius/APKBUILD b/main/freeradius/APKBUILD
index 061273d281..e66e036414 100644
--- a/main/freeradius/APKBUILD
+++ b/main/freeradius/APKBUILD
@@ -5,7 +5,7 @@
# Maintainer: Leonardo Arena <rnalrd@alpinelinux.org>
pkgname=freeradius
pkgver=3.0.21
-pkgrel=6
+pkgrel=7
pkgdesc="RADIUS (Remote Authentication Dial-In User Service) server"
url="https://freeradius.org/"
arch="all"
@@ -385,7 +385,7 @@ _enable_mod() {
sha512sums="85af1c305e99a56400b04be5c966900e7df8beb7b54626d6aa0cb300dc124817e43b424f9b27d86966bb76cca87dce741812ed8d681a568c7d7b63b3b53a9dfa freeradius-server-3.0.21.tar.gz
c3ae1ee6bd7743f883310612ba2c20c6ff7f288fedc308735df05b097ecb2f7fa4d1679b844e262757808978c7bb2d7630b99e4b87ce6d6ba7f84013f9c49f1d freeradius.logrotated
bb3df1fa2c9ed95514ae090e0f6619c4e3280f424c4351bc79f5254bf1a327fa7d27e5fe3add5ab8d9e5ba3792c9553bd9a0481fe9c5bc34945ce46627ef2638 radiusd.confd
-6b17bfd4151e341917c9b44a60862c24da87ff35f4094a4ec4e27756d44a0fdba3a7c6dca7c82f5e234100e033ae3b286983005ddd9fa8964e0f76bacaa212ee radiusd.initd
+5a8579f06e905117c67f87f0833d0760e81e64f97de7672ecee45775733fae05763edb91c472e313bf58523c713f86815e47cc39c841f4c141aa59a5930113c6 radiusd.initd
9f6a4f76fd06e81cfcfe4536f1f8be494634b07e548a6f7e651e5501aded24b030ed7d57dbdc867ae0eb39ee4a090234c4122a89bed84c13733c77de36b9c2cf setup-freeradius.in
5f940e200aa39b2fbbfaf5b24f2ad99869fa75bb7e2008876940ea96cb9dbc7f2b27dd1672aa56cdb5243faabdcbc38875594dd8792af965987183c0aa2aefd1 print-var.mk
c49e5eec7497fccde5fd09dba1ea9b846e57bc88015bd81640aa531fb5c9b449f37136f42c85fe1d7940c5963aed664b85da28442b388c9fb8cc27873df03b2d musl-fix-headers.patch
diff --git a/main/freeradius/radiusd.initd b/main/freeradius/radiusd.initd
index a1ad43aa82..e5f3fae359 100644
--- a/main/freeradius/radiusd.initd
+++ b/main/freeradius/radiusd.initd
@@ -1,5 +1,4 @@
#!/sbin/openrc-run
-supervisor=supervise-daemon
name="FreeRADIUS"
description_checkconfig="Check configuration"
@@ -14,6 +13,9 @@ cfgname="${cfgfile##*/}"
command="/usr/sbin/radiusd"
# RADIUSD_OPTS is for backward compatibility only
command_args="-f -d ${cfgfile%/*} -n ${cfgname%.conf} ${command_args:-$RADIUSD_OPTS}"
+command_background="yes"
+pidfile="/run/$RC_SVCNAME.pid"
+
required_files="$cfgfile"
depend() {
@@ -36,6 +38,11 @@ checkconfig() {
reload () {
ebegin "Reloading $name"
- $supervisor ${command##*\/} --signal HUP
+
+ if [ "$supervisor" ]; then
+ $supervisor "$RC_SVCNAME" --signal HUP
+ else
+ start-stop-daemon --signal HUP --pidfile "$pidfile"
+ fi
eend $?
}