aboutsummaryrefslogtreecommitdiff
path: root/profiles/remote-builder.nix
blob: 3aa772fad4355d585fb9b73cb52d429761cdeade (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
{ config, ... }:
{
  nix.buildMachines = [
    {
      hostName = "builder";
      sshUser = "builder";

      protocol = "ssh";

      sshKey = config.age.secrets.ssh-remote-builder.path;

      systems = [
        "x86_64-linux"
      ];

      maxJobs = 4;

      supportedFeatures = [
        "nixos-test"
      ];
    }
  ];

  nix.distributedBuilds = true;

  programs.ssh.extraConfig = ''
    Host builder
      User builder
      HostName rivendell
      IdentityFile ${config.age.secrets.ssh-remote-builder.path}
  '';
}