Open Frontear opened 1 month ago
https://docs.nixbuild.net/getting-started/
programs.ssh.extraConfig = ''
Host eu.nixbuild.net
PubkeyAcceptedKeyTypes ssh-ed25519
ServerAliveInterval 60
IPQoS throughput
IdentityFile /path/to/your/private/key
'';
programs.ssh.knownHosts = {
nixbuild = {
hostNames = [ "eu.nixbuild.net" ];
publicKey = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPIQCZc54poJ8vqawd8TraNryQeJnvH1eLpIDgbiqymM";
};
};
nix = {
distributedBuilds = true;
buildMachines = [
{ hostName = "eu.nixbuild.net";
system = "x86_64-linux";
maxJobs = 100;
supportedFeatures = [ "benchmark" "big-parallel" ];
}
];
};
Extremely low priority. This issue is largely being made to document the process so that I do not need to stumble around in documentation hell.
1) Generate an ssh key on the local machine, send the public part to the remote machine (via
users.users.<name>.openssh.authorizedKeys.keys/keyFiles
). 2) Create a/root/.ssh/config
on the local machine that contains this minimum snippet3) Create a build user on the remote machine via this minimal snippet
4) On the local machine, use this configuration to attach the builder
That's it. What a disgustingly annoying set of tips, full of imperative behaviour too. Ideally I want to set this up behind a module and in a significantly saner way, sometime in the near future.