From 616421e94e9f91924b0f9cf7de1ae8cde578b70f Mon Sep 17 00:00:00 2001 From: Bill Nottingham Date: Thu, 17 Feb 2011 14:54:37 -0500 Subject: Accept --ignore-dependencies, --skip-redirect in /sbin/service. --- service | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'service') diff --git a/service b/service index 276d72ab..1a426356 100755 --- a/service +++ b/service @@ -26,6 +26,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 + ;; *) if [ -z "${SERVICE}" -a $# -eq 1 -a "${1}" = "--status-all" ]; then cd ${SERVICEDIR} @@ -60,7 +68,7 @@ while [ $# -gt 0 ]; do done if [ -f "${SERVICEDIR}/${SERVICE}" ]; then - env -i PATH="$PATH" TERM="$TERM" "${SERVICEDIR}/${SERVICE}" ${OPTIONS} + env -i PATH="$PATH" TERM="$TERM" SYSTEMCTL_IGNORE_DEPENDENCIES=${SYSTEMCTL_IGNORE_DEPENDENCIES} SYSTEMCTL_SKIP_REDIRECT=${SYSTEMCTL_SKIP_REDIRECT} "${SERVICEDIR}/${SERVICE}" ${OPTIONS} elif [ -f "${SYSTEMDSERVICEDIR}/${SERVICE}.service" ]; then echo $"Redirecting to /bin/systemctl ${OPTIONS} ${SERVICE}.service" >/dev/stderr exec /bin/systemctl ${OPTIONS} ${SERVICE}.service -- cgit v1.2.1