systemd: install all dracut units in /etc and let the generator cp to /run
authorHarald Hoyer <harald@redhat.com>
Tue, 10 Jul 2012 14:20:23 +0000 (16:20 +0200)
committerHarald Hoyer <harald@redhat.com>
Tue, 10 Jul 2012 15:02:42 +0000 (17:02 +0200)
commitbef2fd9722c6f2fd972515c41963639e3bae0bc7
tree3fd98a996193b78f1b2ff8f66ee5fc4378c33d15
parentad401d1eaf51677ac324523f9e11869cb29fee11
systemd: install all dracut units in /etc and let the generator cp to /run

All custom units, which should appear in the system later on should be
installed in /etc/systemd. They should have a guard like:
ConditionPathExists=/etc/initrd-release

So, we can later query via systemctl:

$ systemctl status dracut-initqueue.service
dracut-initqueue.service - Dracut initqueue hook
 Loaded: loaded (/run/systemd/system/dracut-initqueue.service; enabled-runtime)
 Active: inactive (dead) since Tue, 10 Jul 2012 16:01:22 +0200; 1min 37s ago
         start condition failed at Tue, 10 Jul 2012 16:01:23 +0200; 1min 36s ago
 Main PID: 173 (code=exited, status=0/SUCCESS)
 CGroup: name=systemd:/system/dracut-initqueue.service

Jul 10 16:01:22 lenovo dracut-initqueue[173]: Checking, if btrfs device complete
Jul 10 16:01:22 lenovo dracut-initqueue[173]: Remounting /dev/disk/by-uuid/ade13292-d23f-45be-b732-fa9a391a56b0 with -o compress=lzo,ssd,rw
Jul 10 16:01:22 lenovo dracut-initqueue[173]: Mounted root filesystem /dev/sda3
modules.d/98systemd/module-setup.sh
modules.d/98systemd/service-to-run.sh