Added persistence to ssh host keys

This commit is contained in:
Jan-Bulthuis 2025-05-29 20:28:07 +02:00
parent cd91944b1e
commit 76e609372f

View File

@ -11,5 +11,17 @@ in
config = mkIf cfg.enable {
services.openssh.enable = true;
# TODO: Is this default configuration secure?
services.openssh.hostKeys = mkIf (config.modules.impermanence.enable) [
{
type = "ed25519";
path = "/persist/system/etc/ssh/ssh_host_ed25519_key";
}
{
type = "rsa";
bits = 4096;
path = "/persist/system/etc/ssh/ssh_host_rsa_key";
}
];
};
}