Fix error in determin systemd support for debian 13 and newer.
This commit is contained in:
@@ -145,12 +145,12 @@ fi
|
||||
|
||||
# - Systemd supported ?
|
||||
# -
|
||||
systemd_supported=false
|
||||
SYSTEMD_EXISTS=false
|
||||
systemd=$(which systemd)
|
||||
systemctl=$(which systemctl)
|
||||
|
||||
if [[ -n "$systemd" ]] && [[ -n "$systemctl" ]] ; then
|
||||
systemd_supported=true
|
||||
if [[ -n "$systemd" ]] || [[ -n "$systemctl" ]] ; then
|
||||
SYSTEMD_EXISTS=true
|
||||
fi
|
||||
|
||||
|
||||
@@ -382,7 +382,7 @@ if ! diff "$(realpath "$cert_installed")" "$(realpath "$cert_newest")" > /dev/nu
|
||||
# -
|
||||
echo ""
|
||||
echononl " Restart Service '$SERVICE_NAME'.."
|
||||
if $systemd_supported ; then
|
||||
if $SYSTEMD_EXISTS ; then
|
||||
|
||||
systemctl restart "$SERVICE_NAME" > $log_file 2>&1
|
||||
|
||||
|
||||
Reference in New Issue
Block a user