Commit 5b6a2add authored by Pavel Shilovsky's avatar Pavel Shilovsky

serv-status: fix systemd support

parent b8bc3c60
...@@ -48,7 +48,7 @@ is_service_autostart() ...@@ -48,7 +48,7 @@ is_service_autostart()
fatal "FIXME: don't know how detect current startup state" fatal "FIXME: don't know how detect current startup state"
;; ;;
systemd) systemd)
sudocmd systemctl is-enabled $1 sudocmd systemctl is-enabled $1.service
;; ;;
*) *)
fatal "Do not known command for $SERVICETYPE" fatal "Do not known command for $SERVICETYPE"
...@@ -71,7 +71,7 @@ serv_status() ...@@ -71,7 +71,7 @@ serv_status()
sudocmd /etc/init.d/$SERVICE status "$@" sudocmd /etc/init.d/$SERVICE status "$@"
;; ;;
systemd) systemd)
sudocmd systemctl status $service "$@" sudocmd systemctl status $SERVICE.service "$@"
;; ;;
*) *)
fatal "Do not known command for $SERVICETYPE" fatal "Do not known command for $SERVICETYPE"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment