Skip to content

Commit

Permalink
dns/knot-resolver: Fix service status
Browse files Browse the repository at this point in the history
Add status() function to rc script.

PR:		266320
Reported by:	yonas.yanfa@gmail.com
Approved by:	freebsd@dns.company (maintainer, timeout > 1 month)
  • Loading branch information
fernape committed Oct 12, 2022
1 parent 91ef273 commit e2e231d
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions dns/knot-resolver/files/kresd.in
Expand Up @@ -62,4 +62,14 @@ kresd_stop() {
fi
}

kresd_status() {
if [ -e "${pidfile}" ]; then
echo "${name} is running on pid $(cat $pidfile)."
return 1
else
echo "${name} is not running."
return 0
fi
}

run_rc_command "$1"

0 comments on commit e2e231d

Please sign in to comment.