21 lines
454 B
Bash
Executable File
21 lines
454 B
Bash
Executable File
#!/bin/bash -e
|
|
### Copyright 1999-2025. WebPros International GmbH. All rights reserved.
|
|
|
|
case "$1" in
|
|
cleanup)
|
|
shift
|
|
! /bin/systemctl is-active -q "$@" || /bin/systemctl stop "$@"
|
|
! /bin/systemctl is-failed -q "$@" || /bin/systemctl reset-failed "$@"
|
|
;;
|
|
status|show|stop|kill)
|
|
exec /bin/systemctl "$@"
|
|
;;
|
|
version)
|
|
set -o pipefail
|
|
/bin/systemctl --version | head -n1 | cut -d' ' -f2
|
|
;;
|
|
*)
|
|
exec /usr/bin/systemd-run "$@"
|
|
;;
|
|
esac
|