Hey Michael,

Michael Biebl [2015-02-27 13:54 +0100]:
> Lacking this API, we can deduce this state ourselves, by applying the
> same algorithm as the sysv-generator.

I'd actually go a step further and just use the output of
systemd-generator.

> Martin, how exactly would you use the state in /run state derive the
> enabled/disabled state of the service?

I'd just check if the unit in /run/systemd/generator.late/ is enabled.
I. e. something like "systemctl --runtime is-enabled foo.service".
That doesn't work (--runtime isn't defined for is-enabled), but it
would match what --runtime does for enable/disable.

At least that ought to work, no?

Martin

-- 
Martin Pitt                        | http://www.piware.de
Ubuntu Developer (www.ubuntu.com)  | Debian Developer  (www.debian.org)

Attachment: signature.asc
Description: Digital signature

Reply via email to