Luks SSH cleanup + disable console on eidola
This commit is contained in:
parent
134d049a7b
commit
a077e98cf3
|
@ -70,12 +70,13 @@
|
|||
|
||||
# My modules
|
||||
gen.hardening.disableSack = true;
|
||||
gen.hardening.disableConsole = true;
|
||||
gen.bootloader.luksSsh = {
|
||||
enable = true;
|
||||
useDhcp = true;
|
||||
port = 48722;
|
||||
hostKeys = ["/persist/etc/secrets/initrd/ssh_host_ed25519_key"];
|
||||
};
|
||||
boot.initrd.network.udhcpc.enable = true;
|
||||
|
||||
system.stateVersion = "24.05";
|
||||
}
|
||||
|
|
|
@ -101,6 +101,7 @@ in {
|
|||
gen.hardening.disableSack = true;
|
||||
gen.bootloader.luksSsh = {
|
||||
enable = true;
|
||||
useDhcp = false;
|
||||
port = 48722;
|
||||
hostKeys = ["/persist/etc/secrets/initrd/ssh_host_ed25519_key"];
|
||||
};
|
||||
|
|
|
@ -8,7 +8,8 @@ with lib; let
|
|||
cfg = baseCfg.luksSsh;
|
||||
in {
|
||||
options.gen.bootloader.luksSsh = {
|
||||
enable = mkEnableOption "use boot process with luks unlock over ssh";
|
||||
enable = mkEnableOption "boot process with luks unlock over ssh";
|
||||
useDhcp = mkEnableOption "dhcp";
|
||||
port = mkOption {
|
||||
type = types.port;
|
||||
description = "port for ssh server to listen on";
|
||||
|
@ -20,22 +21,11 @@ in {
|
|||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
# ### Use systemd-boot ###
|
||||
# boot.loader = {
|
||||
# efi.canTouchEfiVariables = true;
|
||||
|
||||
# timeout = 2;
|
||||
# systemd-boot = {
|
||||
# enable = true;
|
||||
# configurationLimit = 3;
|
||||
# };
|
||||
# };
|
||||
|
||||
### LUKS unlock through SSH ###
|
||||
boot.initrd = {
|
||||
network = {
|
||||
boot.initrd.network = {
|
||||
enable = true;
|
||||
flushBeforeStage2 = true;
|
||||
udhcpc.enable = cfg.useDhcp;
|
||||
|
||||
ssh = {
|
||||
enable = true;
|
||||
|
@ -49,5 +39,4 @@ in {
|
|||
'';
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue