Skip to content

Commit

Permalink
backend: Make sure to mach user when stopping proc
Browse files Browse the repository at this point in the history
Pass user to start-stop-daemon when stopping nipapd in init script.
  • Loading branch information
garberg committed Oct 24, 2023
1 parent 49bc64c commit 11390c0
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion nipap/debian/nipapd.init
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ CONFIGFILE=/etc/nipap/nipap.conf
NAME=NIPAPd
PIDFILE=/var/run/nipap/nipapd.pid
PIDDIR=`dirname $PIDFILE`
USER=nipap

. /lib/lsb/init-functions

Expand Down Expand Up @@ -74,7 +75,7 @@ case "$1" in
log_daemon_msg "Stopping NIPAPd XML-RPC server" "nipapd"
RUNNING=$(running)
if [ -n "$RUNNING" ]; then
if start-stop-daemon --stop --pidfile $PIDFILE --retry 30; then
if start-stop-daemon --stop --pidfile $PIDFILE --user $USER --retry 30; then
log_end_msg 0
else
log_end_msg 1
Expand Down

0 comments on commit 11390c0

Please sign in to comment.