ubuntu-init-switch: fix for determining if systemd
/run/systemd/ seems to exist even if systemd is not the init system. but /run/systemd/system/ only exists if it has been used as init.
This commit is contained in:
parent
b14f059ae9
commit
cb878b7cb1
@ -111,7 +111,7 @@ def handle(name, cfg, cloud, log, args):
|
||||
log.warn("%s: target set to %s, expected one of: %s",
|
||||
name, target, str(supported))
|
||||
|
||||
if os.path.exists("/run/systemd"):
|
||||
if os.path.exists("/run/systemd/system"):
|
||||
current = "systemd"
|
||||
else:
|
||||
current = "upstart"
|
||||
|
Loading…
x
Reference in New Issue
Block a user