[systemd-devel] Python wrappers for the DBus API
david at davidstrauss.net
Mon Mar 4 21:40:42 PST 2013
We're about to code a Python wrapper for systemd's DBus functionality.
Initially, it will be non-comprehensive and satisfy our internal
Pantheon goal of reading fields on a service and manipulating services
without forking and parsing systemctl output to do either.
But, a clean, incomplete implementation is a great way to kick off
more barn-raising  in the community, so we're aiming for upstream
integration. It's been awesome to see the journal wrappers evolve well
beyond the initial, bare-bones send-to-the-journal code .
Does anyone have in mind any brilliantly Pythonic way to expose the
DBus unit and systemd core APIs?
Should there be a Python class model that mirrors the systemd "unit"
abstract class and litany of concrete classes (like "mount,"
"service," etc.)? Or is it better to keep the Python code minimal to
ease long-term maintenance as new unit types emerge?
Unlike the journal wrappers, this code will probably be 100% regular
Python. DBus Python support is a well-maintained part of many major
distros, and it's great to leverage that.
| david at davidstrauss.net
| +1 512 577 5827 [mobile]
More information about the systemd-devel