Miss any of our Open RFC calls?Watch the recordings here! »

systemd-manager

0.0.1 • Public • Published

Systemd Manager

About

Uses dbus-native to connect to the systemd.manager

Usage

 
SystemdManager = require "systemd-manager"
 
systemd = new SystemdManager dbusSocket: "/var/run/dbus/system_bus_socket"
 
unitEvents = [ "UnitNew""UnitRemoved""JobNew""JobRemoved""StartupFinished" ]
 
# Systemd is an event emitter 
unitEvent.forEach (event) ->
  systemd.on eventconsole.log
 
# Init systemd 
systemd.init (error, manager) ->
  throw error if error
  manager.RestartUnit "NetworkManager.service""replace"(error, info) ->
    throw error if error
    console.log('info'info)
 

Keywords

none

Install

npm i systemd-manager

DownloadsWeekly Downloads

2

Version

0.0.1

License

GPL

Unpacked Size

38.6 kB

Total Files

5

Last publish

Collaborators

  • avatar