staging: Use a static ssh host key

This commit is contained in:
Tristan Daniël Maat 2023-12-29 16:10:00 +01:00
parent 95b5d4b3bd
commit 4a966412b8
Signed by: tlater
GPG key ID: 49670FD774E43268
6 changed files with 122 additions and 56 deletions
configuration/hardware-specific

View file

@ -16,6 +16,22 @@
networkConfig.DHCP = "yes";
};
# Both so we have a predictable key for the staging env, as well as
# to have a static key for decrypting the sops secrets for the
# staging env.
environment.etc."staging.key" = {
mode = "0400";
source = ../../keys/hosts/staging.key;
};
services.openssh.hostKeys = lib.mkForce [
{
type = "rsa";
bits = 4096;
path = "/etc/staging.key";
}
];
# # Set up VM settings to match real VPS
# virtualisation.memorySize = 3941;
# virtualisation.cores = 2;