diff options
author | Bill Nottingham <notting@redhat.com> | 2010-10-14 15:06:41 -0400 |
---|---|---|
committer | Bill Nottingham <notting@redhat.com> | 2010-10-14 15:06:41 -0400 |
commit | 675389f11ffaab590e9dedabc821e33745e3eb5c (patch) | |
tree | 85d2cd8eac0a728bbd958ad12ea922abb697e171 /systemd/system | |
parent | 2672ac3f85ae49077908774b491fa6c07281295a (diff) | |
download | initscripts-675389f11ffaab590e9dedabc821e33745e3eb5c.tar initscripts-675389f11ffaab590e9dedabc821e33745e3eb5c.tar.gz initscripts-675389f11ffaab590e9dedabc821e33745e3eb5c.tar.bz2 initscripts-675389f11ffaab590e9dedabc821e33745e3eb5c.tar.xz initscripts-675389f11ffaab590e9dedabc821e33745e3eb5c.zip |
Reorganize the systemd bits as we'll have scripts to put in /lib/systemd.
Diffstat (limited to 'systemd/system')
-rw-r--r-- | systemd/system/halt.service | 19 | ||||
-rw-r--r-- | systemd/system/killall.service | 19 | ||||
-rw-r--r-- | systemd/system/poweroff.service | 19 | ||||
-rw-r--r-- | systemd/system/prefdm.service | 22 | ||||
-rw-r--r-- | systemd/system/rc-local.service | 16 | ||||
-rw-r--r-- | systemd/system/reboot.service | 19 | ||||
-rw-r--r-- | systemd/system/single.service | 29 | ||||
-rw-r--r-- | systemd/system/sysinit.service | 19 |
8 files changed, 162 insertions, 0 deletions
diff --git a/systemd/system/halt.service b/systemd/system/halt.service new file mode 100644 index 00000000..a1c0e84f --- /dev/null +++ b/systemd/system/halt.service @@ -0,0 +1,19 @@ +# This file is part of systemd. +# +# systemd is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. + +[Unit] +Description=Halt the system +DefaultDependencies=no +Requires=umount.target killall.service +After=umount.target killall.service + +[Service] +Type=oneshot +RemainAfterExit=yes +Environment=INIT_HALT=HALT RUNLEVEL=0 +ExecStart=/etc/init.d/halt start +StandardOutput=tty diff --git a/systemd/system/killall.service b/systemd/system/killall.service new file mode 100644 index 00000000..953dc19d --- /dev/null +++ b/systemd/system/killall.service @@ -0,0 +1,19 @@ +# This file is part of systemd. +# +# systemd is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. + +[Unit] +Description=Kill all processes +DefaultDependencies=no +Requires=shutdown.target +After=shutdown.target +RefuseManualStart=yes + +[Service] +Type=oneshot +RemainAfterExit=yes +ExecStart=-/etc/init.d/killall start +StandardOutput=tty diff --git a/systemd/system/poweroff.service b/systemd/system/poweroff.service new file mode 100644 index 00000000..28b4a5f4 --- /dev/null +++ b/systemd/system/poweroff.service @@ -0,0 +1,19 @@ +# This file is part of systemd. +# +# systemd is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. + +[Unit] +Description=Power down the system +DefaultDependencies=no +Requires=umount.target killall.service +After=umount.target killall.service + +[Service] +Type=oneshot +RemainAfterExit=yes +Environment=RUNLEVEL=0 +ExecStart=/etc/init.d/halt start +StandardOutput=tty diff --git a/systemd/system/prefdm.service b/systemd/system/prefdm.service new file mode 100644 index 00000000..60a5ed05 --- /dev/null +++ b/systemd/system/prefdm.service @@ -0,0 +1,22 @@ +# This file is part of systemd. +# +# systemd is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. + +[Unit] +Description=Display Manager +After=syslog.target livesys-late.service rc-local.service + +# On Fedora gdm/X11 is on tty1. We explicitly cancel the getty here to +# avoid any races around that. +Conflicts=getty@tty1.service plymouth-quit.service + +[Service] +ExecStart=/etc/X11/prefdm -nodaemon +Restart=restart-always +RestartSec=0 + +[Install] +Alias=display-manager.service diff --git a/systemd/system/rc-local.service b/systemd/system/rc-local.service new file mode 100644 index 00000000..21ecfb23 --- /dev/null +++ b/systemd/system/rc-local.service @@ -0,0 +1,16 @@ +# This file is part of systemd. +# +# systemd is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. + +[Unit] +Description=Local customization + +[Service] +ExecStart=/etc/rc.local start +TimeoutSec=0 +StandardOutput=tty +RemainAfterExit=yes +SysVStartPriority=99 diff --git a/systemd/system/reboot.service b/systemd/system/reboot.service new file mode 100644 index 00000000..622beb58 --- /dev/null +++ b/systemd/system/reboot.service @@ -0,0 +1,19 @@ +# This file is part of systemd. +# +# systemd is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. + +[Unit] +Description=Reboot the system +DefaultDependencies=no +Requires=umount.target killall.service +After=umount.target killall.service + +[Service] +Type=oneshot +RemainAfterExit=yes +Environment=RUNLEVEL=6 +ExecStart=/etc/init.d/reboot start +StandardOutput=tty diff --git a/systemd/system/single.service b/systemd/system/single.service new file mode 100644 index 00000000..d91166b3 --- /dev/null +++ b/systemd/system/single.service @@ -0,0 +1,29 @@ +# This file is part of systemd. +# +# systemd is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. + +# See systemd.special(7) for details + +[Unit] +Description=Rescue Shell +DefaultDependencies=no +Conflicts=multi-user.target shutdown.target +After=sysinit.target +Before=multi-user.target + +[Service] +Type=simple +EnvironmentFile=/etc/sysconfig/init +Environment=HOME=/root +ExecStartPre=-/bin/plymouth --hide-splash +ExecStart=-/bin/bash -c "exec $SINGLE" +ExecStopPost=/bin/systemctl default +StandardInput=tty-force +KillMode=process-group + +# Bash ignores SIGTERM, so we send SIGHUP instead, to ensure that bash +# terminates cleanly. +KillSignal=SIGHUP diff --git a/systemd/system/sysinit.service b/systemd/system/sysinit.service new file mode 100644 index 00000000..860d3a34 --- /dev/null +++ b/systemd/system/sysinit.service @@ -0,0 +1,19 @@ +# This file is part of systemd. +# +# systemd is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. + +[Unit] +Description=System Initialization +DefaultDependencies=no +Conflicts=shutdown.target +Before=shutdown.target emergency.service emergency.target + +[Service] +ExecStart=/etc/rc.d/rc.sysinit +Type=forking +TimeoutSec=0 +StandardInput=tty +RemainAfterExit=yes |