HomeFreeBSD

rc.subr: don't require service to be enabled for `status`

Description

rc.subr: don't require service to be enabled for status

For a service that sets an rcvar, there is a check whether it has been
enabled before the actual command is executed. If the check fails, one
gets a message to enable it and the returned exit status is 0.
However, this is usually undesirable for the status command, which is
a) supposed to check whether the service is running anyway and
b) returns a non-zero exit code if that is not the case.
Thus, skip the check for the status command.

PR: 272282
Reviewed by: emaste

(cherry picked from commit ba793728a840041e93e38bcbff4a7233dc63b722)
(cherry picked from commit f701d9da1d94891dd2edad607a989cad6eb10313)

Details

Provenance
tamelingdaniel_gmail.comAuthored on Jul 1 2023, 8:43 AM
emasteCommitted on Sep 24 2023, 2:07 PM
Parents
rG06bcd6142af1: src.conf.5: regen after SSP option description update
Branches
Unknown
Tags
Unknown