NixOS configuration for HPC cluster
https://docs.hpc.informatik.hs-fulda.de/
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
23 lines
498 B
23 lines
498 B
{ lib, nodes, ... }:
|
|
|
|
with lib;
|
|
|
|
{
|
|
programs.ssh = {
|
|
# Add know-host entries for all machines in the cluster
|
|
knownHosts = mapAttrs
|
|
(name: node: {
|
|
hostNames = [
|
|
node.config.networking.hostName
|
|
node.config.networking.fqdn
|
|
];
|
|
publicKeyFile = node.config.gather.parts."ssh/hostKey".path;
|
|
})
|
|
nodes;
|
|
};
|
|
|
|
gather.parts."ssh/hostKey" = {
|
|
name = "ssh_host_ed25519_key.pub";
|
|
file = "/etc/ssh/ssh_host_ed25519_key.pub";
|
|
};
|
|
}
|