From: Daniel Molkentin Date: Fri, 17 Mar 2017 11:13:19 +0000 (+0100) Subject: units: do not throw a warning in emergency mode if plymouth is not installed (#5528) X-Git-Tag: v234~366 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=7e3ba389191dbc241e05f4d134460bbb832ed60c;p=thirdparty%2Fsystemd.git units: do not throw a warning in emergency mode if plymouth is not installed (#5528) Ideally, plymouth should only be referenced via dependencies, not ExecStartPre's. This at least avoids the confusing error message on minimal installations that do not carry plymouth. --- diff --git a/units/emergency.service.in b/units/emergency.service.in index da68eb8faa0..9f60931a9f5 100644 --- a/units/emergency.service.in +++ b/units/emergency.service.in @@ -17,7 +17,7 @@ Before=shutdown.target [Service] Environment=HOME=/root WorkingDirectory=-/root -ExecStartPre=-/bin/plymouth --wait quit +ExecStartPre=-/bin/sh -c "[ -x /bin/plymouth ] && /bin/plymouth --wait quit" ExecStartPre=-/bin/echo -e 'You are in emergency mode. After logging in, type "journalctl -xb" to view\\nsystem logs, "systemctl reboot" to reboot, "systemctl default" or ^D to\\ntry again to boot into default mode.' ExecStart=-/bin/sh -c "@SULOGIN@; @SYSTEMCTL@ --job-mode=fail --no-block default" Type=idle