-
-
Notifications
You must be signed in to change notification settings - Fork 14.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ZFS: Ask for stage 2 encryption passwords using systemd-ask-password #91344
ZFS: Ask for stage 2 encryption passwords using systemd-ask-password #91344
Conversation
Having a bit of trouble testing this with legacy mountpoints. It asks for the passphrase during boot just fine, but I'm testing with |
@@ -146,6 +148,7 @@ in | |||
# We use `mkAfter` to ensure that LUKS password prompt would be shown earlier than the splash screen. | |||
boot.initrd.preLVMCommands = mkAfter '' | |||
mkdir -p /etc/plymouth | |||
mkdir /run/plymouth |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there any concern around this existing / should we make it -p
just in case?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There's definitely no harm in -p
but it's definitely not necessary. /run
is created extremely early in stage 1.
Just in case something reads stdin, so that `while read ds kl` doesn't miss anything
Co-authored-by: Graham Christensen <graham@grahamc.com>
4828e65
to
e2f1594
Compare
Motivation for this change
Currently, ZFS pools that do not contain the system root file system can only have encrypted datasets that use key files. They cannot use
keylocation=prompt
. This PR fixes this by prompting for passphrases usingsystemd-ask-password
.This PR also ensures Plymouth users can take advantage of this by enabling
systemd-ask-password-plymouth.service
. I did have to steal one line from #84158, specificallymkdir /run/plymouth
. This will have the added benefit of allowing other services to usesystemd-ask-password
during boot without breaking for plymouth users. Note that you need to setvirtualisation.useBootLoader = true
in order to test plymouth withnixos-rebuild build-vm
.Relevant: #84158, #88789
Things done
sandbox
innix.conf
on non-NixOS linux)nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
./result/bin/
)nix path-info -S
before and after)