2010-07-12 22:04:14 +00:00
# This file is part of systemd.
#
# systemd is free software; you can redistribute it and/or modify it
2012-04-11 22:20:58 +00:00
# under the terms of the GNU Lesser General Public License as published by
# the Free Software Foundation; either version 2.1 of the License, or
2010-07-12 22:04:14 +00:00
# (at your option) any later version.
# See systemd.special(7) for details
[Unit]
Description=Rescue Shell
DefaultDependencies=no
2010-10-29 02:09:36 +00:00
Conflicts=shutdown.target
2011-09-22 21:52:38 +00:00
After=basic.target plymouth-start.service
2010-10-29 02:09:36 +00:00
Before=shutdown.target
2010-07-12 22:04:14 +00:00
[Service]
2010-09-10 14:53:53 +00:00
Environment=HOME=/root
2010-09-10 15:11:29 +00:00
WorkingDirectory=/root
2011-02-23 17:42:08 +00:00
ExecStartPre=-/bin/plymouth quit
2012-04-04 11:52:02 +00:00
ExecStartPre=-/bin/echo -e 'Welcome to rescue mode! Type "systemctl default" or ^D to enter default mode.\\nType "journalctl" to view system logs. Type "systemctl reboot" to reboot.'
2010-10-29 02:09:36 +00:00
m4_ifdef(`TARGET_FEDORA',
`EnvironmentFile=/etc/sysconfig/init
2010-10-29 14:27:58 +00:00
ExecStart=-/bin/bash -c "exec ${SINGLE}"',
2011-03-08 18:47:29 +00:00
m4_ifdef(`TARGET_MANDRIVA',
`EnvironmentFile=/etc/sysconfig/init
ExecStart=-/bin/bash -c "exec ${SINGLE}"',
2011-10-28 17:16:33 +00:00
m4_ifdef(`TARGET_MAGEIA',
`EnvironmentFile=/etc/sysconfig/init
ExecStart=-/bin/bash -c "exec ${SINGLE}"',
2011-04-19 19:37:51 +00:00
m4_ifdef(`TARGET_MEEGO',
`EnvironmentFile=/etc/sysconfig/init
2011-09-21 19:38:46 +00:00
ExecStart=-/bin/bash -c "exec ${SINGLE}"',
2011-10-28 17:16:33 +00:00
`ExecStart=-/sbin/sulogin'))))
2012-04-04 04:22:21 +00:00
ExecStopPost=-@SYSTEMCTL@ --fail --no-block default
2010-07-12 22:04:14 +00:00
StandardInput=tty-force
2011-09-20 10:11:04 +00:00
StandardOutput=inherit
StandardError=inherit
2011-03-29 21:31:38 +00:00
KillMode=process
2010-07-12 22:04:14 +00:00
2010-08-05 18:29:11 +00:00
# Bash ignores SIGTERM, so we send SIGHUP instead, to ensure that bash
2010-07-12 22:04:14 +00:00
# terminates cleanly.
2010-08-05 18:29:11 +00:00
KillSignal=SIGHUP