shared.state.ssh: specify hostkeys location instead of impermanence
This commit is contained in:
parent
6f261c6b78
commit
c40778e628
1 changed files with 8 additions and 4 deletions
|
@ -1,6 +1,10 @@
|
|||
{
|
||||
environment.persistence.root.files = [
|
||||
"/etc/ssh/ssh_host_ed25519_key"
|
||||
"/etc/ssh/ssh_host_rsa_key"
|
||||
{ config, ... }:
|
||||
|
||||
let
|
||||
statePath = config.environment.persistence.root.persistentStoragePath + "/etc/ssh";
|
||||
in {
|
||||
services.openssh.hostKeys = [
|
||||
{ path = statePath + "/ssh_host_rsa_key"; type = "rsa"; bits = 4096; }
|
||||
{ path = statePath + "/ssh_host_ed25519_key"; type = "ed25519"; }
|
||||
];
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue