forked from pub-solar/os
initrd: make keyfile optional
This commit is contained in:
parent
0bfe4a135e
commit
27aab3e540
|
@ -23,7 +23,7 @@ with lib; {
|
||||||
|
|
||||||
# Use Keyfile to unlock the root partition to avoid keying in twice.
|
# Use Keyfile to unlock the root partition to avoid keying in twice.
|
||||||
# Allow fstrim to work on it.
|
# Allow fstrim to work on it.
|
||||||
boot.initrd = {
|
boot.initrd = mkIf cfg.enableBootLoader {
|
||||||
secrets = { "/keyfile.bin" = cfg.keyfile; };
|
secrets = { "/keyfile.bin" = cfg.keyfile; };
|
||||||
luks.devices."cryptroot" = {
|
luks.devices."cryptroot" = {
|
||||||
keyFile = "/keyfile.bin";
|
keyFile = "/keyfile.bin";
|
||||||
|
|
Loading…
Reference in a new issue