From: Elan Ruusamäe Date: Sat, 3 Mar 2012 20:35:58 +0000 (+0000) Subject: - systemd bits X-Git-Tag: 0.4.5.4~15 X-Git-Url: http://git.pld-linux.org/?a=commitdiff_plain;ds=sidebyside;h=9871d9bb256eb83f55ccc27ba89b71eb8a3ccf35;p=projects%2Frc-scripts.git - systemd bits svn-id: @12482 --- diff --git a/service b/service index 5567c744..22a6e994 100755 --- a/service +++ b/service @@ -85,6 +85,14 @@ while [ $# -gt 0 ]; do echo "${VERSION}" >&2 exit 0 ;; + --ignore-dependencies) + export SYSTEMCTL_IGNORE_DEPENDENCIES=1 + shift + ;; + --skip-redirect) + export SYSTEMCTL_SKIP_REDIRECT=1 + shift + ;; --upstart) USE_UPSTART=yes shift @@ -118,6 +126,9 @@ done if [ -x "${SERVICEDIR}/${SERVICE}" ]; then exec env -i USE_UPSTART=$USE_UPSTART LANG=$LANG PATH=$PATH TERM=$TERM "${SERVICEDIR}/${SERVICE}" ${ACTION} ${OPTIONS} +elif [ -x /bin/systemd_booted ] && systemd_booted; then + echo >&2 "Redirecting to /bin/systemctl ${OPTIONS} ${SERVICE}.service" + exec /bin/systemctl ${OPTIONS} ${SERVICE}.service else echo "${SERVICE}: unrecognized service" >&2 exit 1