contrib/dracut: 90: zfs-{rollback,snapshot}-bootfs: use @sbindir@

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes #11898
This commit is contained in:
наб 2021-04-14 17:30:59 +02:00 committed by Brian Behlendorf
parent ac541438a2
commit c682b67827
2 changed files with 2 additions and 2 deletions

View File

@ -10,5 +10,5 @@ ConditionKernelCommandLine=bootfs.rollback
# ${BOOTFS} should have been set by zfs-env-bootfs.service # ${BOOTFS} should have been set by zfs-env-bootfs.service
Type=oneshot Type=oneshot
ExecStartPre=/bin/sh -c 'test -n "${BOOTFS}"' ExecStartPre=/bin/sh -c 'test -n "${BOOTFS}"'
ExecStart=/bin/sh -c '. /lib/dracut-lib.sh; SNAPNAME="$(getarg bootfs.rollback)"; /sbin/zfs rollback -Rf "${BOOTFS}@${SNAPNAME:-%v}"' ExecStart=/bin/sh -c '. /lib/dracut-lib.sh; SNAPNAME="$(getarg bootfs.rollback)"; @sbindir@/zfs rollback -Rf "${BOOTFS}@${SNAPNAME:-%v}"'
RemainAfterExit=yes RemainAfterExit=yes

View File

@ -10,5 +10,5 @@ ConditionKernelCommandLine=bootfs.snapshot
# ${BOOTFS} should have been set by zfs-env-bootfs.service # ${BOOTFS} should have been set by zfs-env-bootfs.service
Type=oneshot Type=oneshot
ExecStartPre=/bin/sh -c 'test -n "${BOOTFS}"' ExecStartPre=/bin/sh -c 'test -n "${BOOTFS}"'
ExecStart=-/bin/sh -c '. /lib/dracut-lib.sh; SNAPNAME="$(getarg bootfs.snapshot)"; /sbin/zfs snapshot "${BOOTFS}@${SNAPNAME:-%v}"' ExecStart=-/bin/sh -c '. /lib/dracut-lib.sh; SNAPNAME="$(getarg bootfs.snapshot)"; @sbindir@/zfs snapshot "${BOOTFS}@${SNAPNAME:-%v}"'
RemainAfterExit=yes RemainAfterExit=yes