mirror of
https://github.com/nix-community/disko.git
synced 2026-11-30 13:03:28 +01:00
Unlock luks devices once and only once
This commit is contained in:
1 parent
69265ccde5
commit
06fb9283ca
1 file changed
+3
-1
+3
-1
@@ -160,7 +160,9 @@ in
|
||||
cryptsetup -q luksFormat "${config.device}" ${toString config.extraFormatArgs} ${keyFileArgs}
|
||||
fi
|
||||
|
||||
${cryptsetupOpen} --persistent
|
||||
if ! cryptsetup status "${config.name}" >/dev/null; then
|
||||
${cryptsetupOpen} --persistent
|
||||
fi
|
||||
${toString (
|
||||
lib.forEach config.additionalKeyFiles (keyFile: ''
|
||||
cryptsetup luksAddKey "${config.device}" ${keyFile} ${keyFileArgs}
|
||||
|
||||
Reference in new issue
Block a user