polkit: add flag to disable systemctl
Signed-off-by: Eric Callahan <arksine.code@gmail.com>
This commit is contained in:
parent
3ddbb9553d
commit
d84f93d381
|
@ -113,6 +113,7 @@ verify_ready()
|
|||
|
||||
CLEAR="n"
|
||||
ROOT="n"
|
||||
DISABLE_SYSTEMCTL="n"
|
||||
|
||||
# Parse command line arguments
|
||||
while :; do
|
||||
|
@ -123,6 +124,9 @@ while :; do
|
|||
-r|--root)
|
||||
ROOT="y"
|
||||
;;
|
||||
-z|--disable-systemctl)
|
||||
DISABLE_SYSTEMCTL="y"
|
||||
;;
|
||||
*)
|
||||
break
|
||||
esac
|
||||
|
@ -140,6 +144,8 @@ else
|
|||
set -e
|
||||
check_moonraker_service
|
||||
add_polkit_rules
|
||||
report_status "Restarting Moonraker..."
|
||||
sudo systemctl restart moonraker
|
||||
if [ $DISABLE_SYSTEMCTL = "n" ]; then
|
||||
report_status "Restarting Moonraker..."
|
||||
sudo systemctl restart moonraker
|
||||
fi
|
||||
fi
|
||||
|
|
Loading…
Reference in New Issue