Add a host for hydra.

This commit is contained in:
Tom Alexander
2025-11-27 17:51:08 -05:00
parent 8eb3c459bd
commit 4ca486d7f8
14 changed files with 121 additions and 216 deletions

View File

@@ -2,6 +2,7 @@
config,
lib,
all_nixos_configs,
pkgs,
...
}:
@@ -56,6 +57,21 @@ in
lib.mkMerge [
{
nix.distributedBuilds = true;
nix.settings.substituters = lib.mkForce [ "ssh://hydra" ];
nix.settings.substitute = lib.mkForce true;
nix.settings.post-build-hook = pkgs.writeShellScript "post-build-hook" ''
set -euo pipefail
IFS=$'\n\t'
set -f # disable globbing
echo "Signing and uploading paths" $OUT_PATHS
#exec nix copy --to 'ssh://hydra?secret-key=/persist/manual/nix/nix-cache-key.sec' $OUT_PATHS
exec nix copy --to 'ssh://hydra' $OUT_PATHS
'';
nix.settings.secret-key-files = [ "/persist/manual/nix/nix-cache-key.sec" ];
nix.settings.trusted-public-keys = lib.mkForce [
"odo:0S/XKSFjjIrihQ7lbHEIebXk/c/xuoodhm0Gz26YhjA="
];
}
{
nix.buildMachines = (

View File

@@ -307,7 +307,7 @@ function start_body {
local additional_args=()
if [ -n "$BIND9P" ]; then
additional_args+=(-device "virtio-9p-type,fsdev=${BIND9P},mount_tag=bind9p")
additional_args+=(-device "virtio-9p-pci,fsdev=${BIND9P},mount_tag=bind9p")
fi
if [ -n "$mount_cd" ]; then