systemd/switch-root.service: do not require shutdown and isolate to default
authorHarald Hoyer <harald@redhat.com>
Wed, 16 May 2012 09:22:28 +0000 (11:22 +0200)
committerHarald Hoyer <harald@redhat.com>
Wed, 16 May 2012 09:22:28 +0000 (11:22 +0200)
do not require shutdown.target and final.target

After switch-root isolate to the default target. This will load the
default target in the real root after systemd deserializes.

modules.d/98systemd/switch-root.service

index f72739e..0c41eb0 100644 (file)
@@ -8,10 +8,9 @@
 [Unit]
 Description=Switch Root
 DefaultDependencies=no
-Requires=shutdown.target final.target
-After=shutdown.target final.target
 
 [Service]
 Type=oneshot
 EnvironmentFile=/etc/switch-root.conf
 ExecStart=/usr/bin/systemctl --force switch-root ${NEWROOT} ${NEWINIT}
+ExecStopPost=-/usr/bin/systemctl isolate default.target