Skip to content

Instantly share code, notes, and snippets.

@aristidb
Created March 12, 2018 21:30
Show Gist options
  • Save aristidb/8de537c9af2f81c7b0ca465d0e31e433 to your computer and use it in GitHub Desktop.
Save aristidb/8de537c9af2f81c7b0ca465d0e31e433 to your computer and use it in GitHub Desktop.
{ pkgs, config, ... }:
{
nix.buildMachines = [
{
hostName = "iridium";
maxJobs = 8;
sshKey = "/root/.ssh/id_buildfarm";
sshUser = "nixbuildfarm";
system = "x86_64-linux";
supportedFeatures = ["big-parallel"];
}
];
nix.distributedBuilds = true;
nix.binaryCachePublicKeys = ["iridium-1:EVENAPUBLICKEYCANBECENSORED"];
}
{ pkgs, config, ... }:
{
users.extraUsers.nixbuildfarm = {
uid = 31000;
useDefaultShell = true;
openssh.authorizedKeys.keyFiles = [
../../ssh/cobalt_buildfarm.pub
];
};
nix.extraOptions = ''
secret-key-files = /etc/_credentials/nix-store-iridium.private
'';
nix.trustedUsers = ["root" "nixbuildfarm"];
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment