module LoomExt::CoreMods::Systemd::Actions
Public Instance Methods
disable(unit)
click to toggle source
# File lib/loomext/coremods/systemd/systemd.rb, line 47 def disable(unit) do_systemctl "disable", unit end
enable(unit)
click to toggle source
# File lib/loomext/coremods/systemd/systemd.rb, line 39 def enable(unit) do_systemctl "enable", unit end
is_active?(unit)
click to toggle source
# File lib/loomext/coremods/systemd/systemd.rb, line 31 def is_active?(unit) do_systemctl "is-active", unit end
is_loaded?(unit)
click to toggle source
# File lib/loomext/coremods/systemd/systemd.rb, line 27 def is_loaded?(unit) status(unit).match? /^\s+Loaded:\sloaded\s/ end
link(path)
click to toggle source
# File lib/loomext/coremods/systemd/systemd.rb, line 59 def link(path) do_systemctl "link", path end
restart(unit)
click to toggle source
# File lib/loomext/coremods/systemd/systemd.rb, line 51 def restart(unit) do_systemctl "restart", unit end
start(unit)
click to toggle source
# File lib/loomext/coremods/systemd/systemd.rb, line 43 def start(unit) do_systemctl "start", unit end
status(unit)
click to toggle source
# File lib/loomext/coremods/systemd/systemd.rb, line 35 def status(unit) do_systemctl "status", unit end
stop(unit)
click to toggle source
# File lib/loomext/coremods/systemd/systemd.rb, line 55 def stop(unit) do_systemctl "stop", unit end