Fix non-absolute path in systemd mount generator
Systemd will ignore units that try to execute programs from non-absolute paths. Use hardcoded /bin/sh instead. Reviewed-by: Antonio Russo <antonio.e.russo@gmail.com> Reviewed-by: Richard Laager <rlaager@wiktel.com> Signed-off-by: InsanePrawn <insane.prawny@gmail.com> Closes #9611
This commit is contained in:
parent
d8ce455c1e
commit
70d2dd922b
|
@ -181,7 +181,7 @@ process_line() {
|
||||||
pathdep="RequiresMountsFor='${p_keyloc#file://}'"
|
pathdep="RequiresMountsFor='${p_keyloc#file://}'"
|
||||||
keyloadcmd="@sbindir@/zfs load-key '${dataset}'"
|
keyloadcmd="@sbindir@/zfs load-key '${dataset}'"
|
||||||
elif [ "${p_keyloc}" = "prompt" ] ; then
|
elif [ "${p_keyloc}" = "prompt" ] ; then
|
||||||
keyloadcmd="sh -c 'set -eu;"\
|
keyloadcmd="/bin/sh -c 'set -eu;"\
|
||||||
"keystatus=\"\$\$(@sbindir@/zfs get -H -o value keystatus \"${dataset}\")\";"\
|
"keystatus=\"\$\$(@sbindir@/zfs get -H -o value keystatus \"${dataset}\")\";"\
|
||||||
"[ \"\$\$keystatus\" = \"unavailable\" ] || exit 0;"\
|
"[ \"\$\$keystatus\" = \"unavailable\" ] || exit 0;"\
|
||||||
"count=0;"\
|
"count=0;"\
|
||||||
|
|
Loading…
Reference in New Issue