Skip to content

Instantly share code, notes, and snippets.

@jimi-c
Created October 27, 2014 20:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jimi-c/684612137d29a90b085f to your computer and use it in GitHub Desktop.
Save jimi-c/684612137d29a90b085f to your computer and use it in GitHub Desktop.
def check_systemd(name):
# verify service is managed by systemd
systemd_enabled = 'false'
f = open('/proc/1/cmdline', 'r')
for line in f:
if 'systemd' in line:
return True
return False
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment