summarylogtreecommitdiffstats
path: root/zfs-pivy.hook
diff options
context:
space:
mode:
authorAlex Wilson2020-03-05 22:07:02 +1000
committerAlex Wilson2020-03-05 22:07:02 +1000
commit3a2507b44827c54d3f4187fdf76183178848a19d (patch)
tree59b6d66fc7d597be64f6fef1920decd3958d8d5e /zfs-pivy.hook
parent257461020dc2867cf4702d25b3cba3a63eda857b (diff)
downloadaur-3a2507b44827c54d3f4187fdf76183178848a19d.tar.gz
Typo in initcpio hook prevents unlock of nested datasets
Diffstat (limited to 'zfs-pivy.hook')
-rw-r--r--zfs-pivy.hook4
1 files changed, 3 insertions, 1 deletions
diff --git a/zfs-pivy.hook b/zfs-pivy.hook
index dd5bd3506211..6a01766ff03a 100644
--- a/zfs-pivy.hook
+++ b/zfs-pivy.hook
@@ -40,11 +40,13 @@ zfs_decrypt_fs() {
# get the encryption root
encryptionroot=$(zfs get -H -o value encryptionroot "${dataset}")
+ msg "ZFS: unlocking ${encryptionroot}"
+
# export encription root to be used by other hooks (SSH)
echo "${encryptionroot}" > /.encryptionroot
# if the dataset has an ebox, use pivy-zfs to unlock it
- if [ "$(zfs get -H -o source rfd77:ebox "${dataset}")" == "local" ]; then
+ if [ "$(zfs get -H -o source rfd77:ebox "${encryptionroot}")" == "local" ]; then
# loop until pivy-zfs unlock succeeds
while [ "$(zfs get -H -o value keystatus "${encryptionroot}")" != "available" ] &&
! eval pivy-zfs unlock "${encryptionroot}"; do