support ubuntu upstart in __start_on_boot

Signed-off-by: Nico Schottelius <nico@freiheit.schottelius.org>
remotes/origin/random_dot_cdist
Nico Schottelius 10 years ago
parent 3db2dcb2d6
commit 745f1e2984
  1. 9
      cdist/conf/type/__start_on_boot/explorer/state

@ -1,6 +1,6 @@
#!/bin/sh
#
# 2012-2013 Nico Schottelius (nico-cdist at schottelius.org)
# 2012-2015 Nico Schottelius (nico-cdist at schottelius.org)
# 2013 Daniel Heule (hda at sfs.biz)
#
# This file is part of cdist.
@ -34,10 +34,15 @@ case "$os" in
|| echo absent)
;;
debian|ubuntu|openwrt)
debian|openwrt)
state="present"
[ -f "/etc/rc$runlevel.d/S"??"$name" ] || state="absent"
;;
ubuntu)
state="absent"
[ -f "/etc/rc$runlevel.d/S"??"$name" ] && state="present"
[ -f "/etc/init/${name}.conf" ] && state="present"
;;
amazon|centos|fedora|owl|redhat)
state=$(chkconfig --level "$runlevel" "$name" || echo absent)

Loading…
Cancel
Save