54 lines
1.1 KiB
Nix
54 lines
1.1 KiB
Nix
{config, pkgs, ...}: let
|
|
in {
|
|
imports = [
|
|
# ./nix-serve.nix
|
|
];
|
|
services.hydra = {
|
|
enable = true;
|
|
hydraURL = "https://hydra.syzygial.cc";
|
|
port = 3500;
|
|
notificationSender = "hydra@localhost";
|
|
buildMachinesFiles = [];
|
|
useSubstitutes = true;
|
|
extraConfig = ''
|
|
<dynamicruncommand>
|
|
enable = 1
|
|
</dynamicruncommand>
|
|
'';
|
|
};
|
|
nix.extraOptions = ''
|
|
allowed-uris = https://github.com/ https://git.savannah.gnu.org/ https://git.syzygial.cc https://gitlab.com https://sr.ht github: gitlab:
|
|
'';
|
|
systemd.services.hydra = {
|
|
serviceConfig = {
|
|
RestartSec = "20s";
|
|
};
|
|
};
|
|
users.users."hydra" = {
|
|
openssh.authorizedKeys.keys = [
|
|
|
|
];
|
|
packages = [
|
|
|
|
];
|
|
};
|
|
|
|
nix.buildMachines = [
|
|
{ hostName = "localhost";
|
|
systems = [
|
|
"x86_64-linux"
|
|
"riscv64-linux"
|
|
];
|
|
supportedFeatures = ["kvm" "nixos-test" "big-parallel" "benchmark"];
|
|
maxJobs = 16;
|
|
}
|
|
];
|
|
services.caddy.virtualHosts = {
|
|
"hydra.syzygial.cc" = {
|
|
extraConfig = ''
|
|
reverse_proxy localhost:${toString config.services.hydra.port}
|
|
'';
|
|
};
|
|
};
|
|
}
|