[Main]
Type = classic
Version = 0.0.2
Description = "elogind daemon"
User = ( root )
Depends = ( dbus )

[Start]
Execute = (
  execl-toc -m /sys/fs/cgroup/elogind -t cgroup -o none,name=elogind -d cgroup
  execl-toc -m /run/systemd -t tmpfs -o nosuid,nodev,noexec,mode=0755 -d none
  execl-toc -m /run/user -t tmpfs -o nosuid,nodev,noexec,mode=0755 -d none
  ifelse { test -x /lib/elogind/elogind } { /lib/elogind/elogind }
  /usr/libexec/elogind
)

[Stop]
Execute = ( s6-rmrf ${pid_file} )

[Environment]
pid_file=!/run/elogind.pid
