🔨 Removed logging for service daemon functions

This commit is contained in:
Geoff Murphy 2025-05-13 16:17:09 +10:00
parent 365c07e26f
commit 86bbffa59e

View file

@ -137,8 +137,8 @@ _fake_start () { #--------[ Start Daemon ]
echo "" echo ""
echo "[START] $@" echo "[START] $@"
for SERVICE in $@; do for SERVICE in $@; do
if [ "$(command -v systemctl)" ]; then $FAKE_SUDO systemctl start "$SERVICE" 2>> $FAKE_LOG; fi if [ "$(command -v systemctl)" ]; then $FAKE_SUDO systemctl start "$SERVICE"; fi
if [ "$(command -v rc-update)" ]; then $FAKE_SUDO rc-service "$SERVICE" start 2>> $FAKE_LOG; fi if [ "$(command -v rc-update)" ]; then $FAKE_SUDO rc-service "$SERVICE" start; fi
done done
echo "" echo ""
} }
@ -146,8 +146,8 @@ _fake_stop () { #---------[ Stop Daemon ]
echo "" echo ""
echo "[STOP] $@" echo "[STOP] $@"
for SERVICE in $@; do for SERVICE in $@; do
if [ "$(command -v systemctl)" ]; then $FAKE_SUDO systemctl start "$SERVICE" 2>> $FAKE_LOG; fi if [ "$(command -v systemctl)" ]; then $FAKE_SUDO systemctl start "$SERVICE"; fi
if [ "$(command -v rc-update)" ]; then $FAKE_SUDO rc-service "$SERVICE" start 2>> $FAKE_LOG; fi if [ "$(command -v rc-update)" ]; then $FAKE_SUDO rc-service "$SERVICE" start; fi
done done
echo "" echo ""
} }
@ -155,8 +155,8 @@ _fake_restart () { #------[ Restart Daemon ]
echo "" echo ""
echo "[RESTART] $@" echo "[RESTART] $@"
for SERVICE in $@; do for SERVICE in $@; do
if [ "$(command -v systemctl)" ]; then $FAKE_SUDO systemctl restart "$SERVICE" 2>> $FAKE_LOG; fi if [ "$(command -v systemctl)" ]; then $FAKE_SUDO systemctl restart "$SERVICE"; fi
if [ "$(command -v rc-update)" ]; then $FAKE_SUDO rc-service "$SERVICE" restart 2>> $FAKE_LOG; fi if [ "$(command -v rc-update)" ]; then $FAKE_SUDO rc-service "$SERVICE" restart; fi
done done
echo "" echo ""
} }
@ -164,8 +164,8 @@ _fake_status () { #------[ Status of Daemon ]
echo "" echo ""
echo "[STATUS] $@" echo "[STATUS] $@"
for SERVICE in $@; do for SERVICE in $@; do
if [ "$(command -v systemctl)" ]; then systemctl status "$SERVICE" 2>> $FAKE_LOG; fi if [ "$(command -v systemctl)" ]; then systemctl status "$SERVICE"; fi
if [ "$(command -v rc-update)" ]; then rc-service "$SERVICE" status 2>> $FAKE_LOG; fi if [ "$(command -v rc-update)" ]; then rc-service "$SERVICE" status; fi
done done
echo "" echo ""
} }
@ -173,8 +173,8 @@ _fake_enable () { #-------[ Enable Daemon at Startup ]
echo "" echo ""
echo "[ENABLE] $@" echo "[ENABLE] $@"
for SERVICE in $@; do for SERVICE in $@; do
if [ "$(command -v systemctl)" ]; then $FAKE_SUDO systemctl enable "$SERVICE" 2>> $FAKE_LOG; fi if [ "$(command -v systemctl)" ]; then $FAKE_SUDO systemctl enable "$SERVICE"; fi
if [ "$(command -v rc-update)" ]; then $FAKE_SUDO rc-update add "$SERVICE" 2>> $FAKE_LOG; fi if [ "$(command -v rc-update)" ]; then $FAKE_SUDO rc-update add "$SERVICE"; fi
done done
echo "" echo ""
} }
@ -182,8 +182,8 @@ _fake_disable () { #------[ Disable Daeon at Startup ]
echo "" echo ""
echo "[DISABLE] $@" echo "[DISABLE] $@"
for SERVICE in $@; do for SERVICE in $@; do
if [ "$(command -v systemctl)" ]; then sudo systemctl disable "$SERVICE" 2>> $FAKE_LOG; fi if [ "$(command -v systemctl)" ]; then sudo systemctl disable "$SERVICE"; fi
if [ "$(command -v rc-update)" ]; then sudo rc-update rm "$SERVICE" 2>> $FAKE_LOG; fi if [ "$(command -v rc-update)" ]; then sudo rc-update rm "$SERVICE"; fi
done done
echo "" echo ""
} }