summaryrefslogtreecommitdiffstats
path: root/modules.d/99shutdown
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-06-03 14:01:37 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-06-03 14:01:37 +0000
commit734d725d62d2cbe4445524448de024e3b9e7f4b3 (patch)
tree88d8385f24a0efda248b3480fe39037b85e76552 /modules.d/99shutdown
parentReleasing progress-linux version 060+5-8~progress7.99u1. (diff)
downloaddracut-734d725d62d2cbe4445524448de024e3b9e7f4b3.tar.xz
dracut-734d725d62d2cbe4445524448de024e3b9e7f4b3.zip
Merging upstream version 102.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'modules.d/99shutdown')
-rwxr-xr-xmodules.d/99shutdown/module-setup.sh8
-rwxr-xr-xmodules.d/99shutdown/shutdown.sh4
2 files changed, 7 insertions, 5 deletions
diff --git a/modules.d/99shutdown/module-setup.sh b/modules.d/99shutdown/module-setup.sh
index 2b99902..f53017f 100755
--- a/modules.d/99shutdown/module-setup.sh
+++ b/modules.d/99shutdown/module-setup.sh
@@ -17,9 +17,11 @@ install() {
inst_multiple umount poweroff reboot halt losetup stat sleep timeout
inst_multiple -o kexec
inst "$moddir/shutdown.sh" "$prefix/shutdown"
- [ -e "${initdir}/lib" ] || mkdir -m 0755 -p "${initdir}"/lib
- mkdir -m 0755 -p "${initdir}"/lib/dracut
- mkdir -m 0755 -p "${initdir}"/lib/dracut/hooks
+ mkdir -m 0755 -p "${initdir}"/var/lib/dracut/hooks
+
+ # symlink to old hooks location for compatibility
+ ln_r /var/lib/dracut/hooks /lib/dracut/hooks
+
for _d in $hookdirs shutdown shutdown-emergency; do
mkdir -m 0755 -p "${initdir}"/lib/dracut/hooks/"$_d"
done
diff --git a/modules.d/99shutdown/shutdown.sh b/modules.d/99shutdown/shutdown.sh
index d611d44..d48d7d1 100755
--- a/modules.d/99shutdown/shutdown.sh
+++ b/modules.d/99shutdown/shutdown.sh
@@ -39,7 +39,7 @@ if [ "$ACTION" = "kexec" ] && ! command -v kexec > /dev/null 2>&1; then
fi
trap "emergency_shell --shutdown shutdown Signal caught!" 0
-getarg 'rd.break=pre-shutdown' && emergency_shell --shutdown pre-shutdown "Break before pre-shutdown"
+getargs 'rd.break=pre-shutdown' && emergency_shell --shutdown pre-shutdown "Break before pre-shutdown"
source_hook pre-shutdown
@@ -155,7 +155,7 @@ elif [ -x /oldroot/bin/plymouth ]; then
/oldroot/bin/plymouth --hide-splash
fi
-getarg 'rd.break=shutdown' && emergency_shell --shutdown shutdown "Break before shutdown"
+getargs 'rd.break=shutdown' && emergency_shell --shutdown shutdown "Break before shutdown"
case "$ACTION" in
reboot | poweroff | halt)