nix-config/hosts/hydra/hydra.nix

40 lines
989 B
Nix

{ config, pkgs, ... }:
{
nix = {
binaryCaches = [ "https://cache.nixos.org" "https://cache.dhall-lang.org" ];
binaryCachePublicKeys =
[ "cache.dhall-lang.org:I9/H18WHd60olG5GsIjolp7CtepSgJmM2CsO813VTmM=" ];
buildMachines = [{
hostName = "server7.hq.c3d2.de";
system = "x86_64-linux";
sshUser = "buildfarmer";
sshKey = "/root/.ssh/id_ed25519";
maxJobs = 10;
}];
extraOptions = ''
allowed-uris = http:// https://
'';
};
services.hydra = {
enable = true;
hydraURL = "https://hydra.hq.c3d2.de";
logo = ./c3d2.svg;
notificationSender = "hydra@spam.works";
useSubstitutes = false;
};
services.nginx = {
enable = true;
recommendedProxySettings = true;
recommendedGzipSettings = true;
virtualHosts."hydra.hq.c3d2.de" = {
forceSSL = true;
enableACME = true;
locations."/".proxyPass =
"http://localhost:${toString config.services.hydra.port}";
};
};
}