add remote hydra eval
Some checks failed
Hydra packages.aarch64-linux.emoji-volpeon-gphn Hydra build #28608 of nixos-config:pr634:packages.aarch64-linux.emoji-volpeon-gphn
Hydra packages.x86_64-linux.nasin-nanpa Hydra build #28679 of nixos-config:pr634:packages.x86_64-linux.nasin-nanpa
Hydra packages.x86_64-linux.mautrix-telegram Hydra build #28675 of nixos-config:pr634:packages.x86_64-linux.mautrix-telegram
Hydra packages.aarch64-linux.emoji-rosaflags Hydra build #28600 of nixos-config:pr634:packages.aarch64-linux.emoji-rosaflags
Hydra packages.x86_64-linux.emoji-volpeon-neofox Hydra build #28665 of nixos-config:pr634:packages.x86_64-linux.emoji-volpeon-neofox
Hydra packages.x86_64-linux.emoji-rosaflags Hydra build #28655 of nixos-config:pr634:packages.x86_64-linux.emoji-rosaflags
Hydra packages.x86_64-linux.emoji-volpeon-neocat Hydra build #28664 of nixos-config:pr634:packages.x86_64-linux.emoji-volpeon-neocat
Hydra packages.x86_64-linux.emoji-raccoon Hydra build #28654 of nixos-config:pr634:packages.x86_64-linux.emoji-raccoon
Hydra packages.x86_64-linux.emoji-volpeon-blobfox-flip Hydra build #28657 of nixos-config:pr634:packages.x86_64-linux.emoji-volpeon-blobfox-flip
Hydra packages.x86_64-linux.asar-asm Hydra build #28649 of nixos-config:pr634:packages.x86_64-linux.asar-asm
Hydra packages.aarch64-linux.papermc Hydra build #28625 of nixos-config:pr634:packages.aarch64-linux.papermc
Hydra packages.x86_64-linux.plover-plugin-lapwing-aio Hydra build #28686 of nixos-config:pr634:packages.x86_64-linux.plover-plugin-lapwing-aio
Hydra packages.x86_64-linux.fairfax-hd Hydra build #28669 of nixos-config:pr634:packages.x86_64-linux.fairfax-hd
Hydra packages.x86_64-linux.plover-plugin-dotool-output Hydra build #28684 of nixos-config:pr634:packages.x86_64-linux.plover-plugin-dotool-output
Hydra packages.x86_64-linux.mautrix-discord Hydra build #28673 of nixos-config:pr634:packages.x86_64-linux.mautrix-discord
Hydra packages.aarch64-linux.emoji-volpeon-floof Hydra build #28606 of nixos-config:pr634:packages.aarch64-linux.emoji-volpeon-floof
Hydra packages.aarch64-linux.emoji-volpeon-vlpn Hydra build #28612 of nixos-config:pr634:packages.aarch64-linux.emoji-volpeon-vlpn
Hydra packages.x86_64-linux.mgba-dev Hydra build #28677 of nixos-config:pr634:packages.x86_64-linux.mgba-dev
Hydra packages.aarch64-linux.python-mautrix Hydra build #28642 of nixos-config:pr634:packages.aarch64-linux.python-mautrix
Hydra packages.aarch64-linux.miifox-net Hydra build #28623 of nixos-config:pr634:packages.aarch64-linux.miifox-net
Hydra packages.x86_64-linux.emoji-lotte Hydra build #28653 of nixos-config:pr634:packages.x86_64-linux.emoji-lotte
Hydra packages.aarch64-linux.plover-plugin-emoji Hydra build #28630 of nixos-config:pr634:packages.aarch64-linux.plover-plugin-emoji
Hydra packages.x86_64-linux.mautrix-slack Hydra build #28674 of nixos-config:pr634:packages.x86_64-linux.mautrix-slack
Hydra packages.x86_64-linux.emoji-caro Hydra build #28652 of nixos-config:pr634:packages.x86_64-linux.emoji-caro
Hydra packages.aarch64-linux.plover Hydra build #28626 of nixos-config:pr634:packages.aarch64-linux.plover
Hydra packages.x86_64-linux.plover-plugin-dict-commands Hydra build #28683 of nixos-config:pr634:packages.x86_64-linux.plover-plugin-dict-commands
Hydra packages.x86_64-linux.emoji-volpeon-vlpn Hydra build #28667 of nixos-config:pr634:packages.x86_64-linux.emoji-volpeon-vlpn
Hydra packages.x86_64-linux.plover-plugin-stenotype-extended Hydra build #28692 of nixos-config:pr634:packages.x86_64-linux.plover-plugin-stenotype-extended
Hydra packages.aarch64-linux.alco-sans Hydra build #28593 of nixos-config:pr634:packages.aarch64-linux.alco-sans
Hydra packages.aarch64-linux.plover-plugins-manager Hydra build #28641 of nixos-config:pr634:packages.aarch64-linux.plover-plugins-manager
Hydra packages.aarch64-linux.mautrix-discord Hydra build #28618 of nixos-config:pr634:packages.aarch64-linux.mautrix-discord
Hydra packages.aarch64-linux.python-simplefuzzyset Hydra build #28645 of nixos-config:pr634:packages.aarch64-linux.python-simplefuzzyset
Hydra packages.x86_64-linux.emoji-volpeon-bunhd Hydra build #28658 of nixos-config:pr634:packages.x86_64-linux.emoji-volpeon-bunhd
Hydra packages.aarch64-linux.plover-plugin-dotool-output Hydra build #28629 of nixos-config:pr634:packages.aarch64-linux.plover-plugin-dotool-output
Hydra packages.aarch64-linux.lotte-art Hydra build #28616 of nixos-config:pr634:packages.aarch64-linux.lotte-art
Hydra packages.x86_64-linux.papermc Hydra build #28680 of nixos-config:pr634:packages.x86_64-linux.papermc
Hydra packages.x86_64-linux.emoji-volpeon-fox Hydra build #28662 of nixos-config:pr634:packages.x86_64-linux.emoji-volpeon-fox
Hydra packages.x86_64-linux.plover-plugin-yaml-dictionary Hydra build #28695 of nixos-config:pr634:packages.x86_64-linux.plover-plugin-yaml-dictionary
Hydra packages.aarch64-linux.emoji-caro Hydra build #28597 of nixos-config:pr634:packages.aarch64-linux.emoji-caro
Hydra packages.aarch64-linux.plover-plugin-dict-commands Hydra build #28628 of nixos-config:pr634:packages.aarch64-linux.plover-plugin-dict-commands
Hydra packages.x86_64-linux.kreative-square Hydra build #28670 of nixos-config:pr634:packages.x86_64-linux.kreative-square
Hydra packages.aarch64-linux.python-rtf-tokenize Hydra build #28644 of nixos-config:pr634:packages.aarch64-linux.python-rtf-tokenize
Hydra packages.aarch64-linux.emoji-volpeon-bunhd-flip Hydra build #28604 of nixos-config:pr634:packages.aarch64-linux.emoji-volpeon-bunhd-flip
Hydra devShell.x86_64-linux Hydra build #28589 of nixos-config:pr634:devShell.x86_64-linux
Hydra packages.aarch64-linux.bsnes-plus Hydra build #28595 of nixos-config:pr634:packages.aarch64-linux.bsnes-plus
Hydra packages.aarch64-linux.mautrix-whatsapp Hydra build #28621 of nixos-config:pr634:packages.aarch64-linux.mautrix-whatsapp
Hydra packages.aarch64-linux.plover-plugin-python-dictionary Hydra build #28635 of nixos-config:pr634:packages.aarch64-linux.plover-plugin-python-dictionary
Hydra packages.aarch64-linux.mautrix-slack Hydra build #28619 of nixos-config:pr634:packages.aarch64-linux.mautrix-slack
Hydra packages.aarch64-linux.emoji-volpeon-blobfox-flip Hydra build #28602 of nixos-config:pr634:packages.aarch64-linux.emoji-volpeon-blobfox-flip
Hydra packages.x86_64-linux.emoji-volpeon-drgn Hydra build #28660 of nixos-config:pr634:packages.x86_64-linux.emoji-volpeon-drgn
Hydra packages.x86_64-linux.matrix-media-repo Hydra build #28672 of nixos-config:pr634:packages.x86_64-linux.matrix-media-repo
Hydra nas.x86_64-linux Hydra build #28591 of nixos-config:pr634:nas.x86_64-linux
Hydra nixos-8gb-fsn1-1.x86_64-linux Hydra build #28592 of nixos-config:pr634:nixos-8gb-fsn1-1.x86_64-linux
Hydra packages.x86_64-linux.python-tulir-telethon Hydra build #28701 of nixos-config:pr634:packages.x86_64-linux.python-tulir-telethon
Hydra packages.aarch64-linux.plover-plugin-lapwing-aio Hydra build #28631 of nixos-config:pr634:packages.aarch64-linux.plover-plugin-lapwing-aio
Hydra packages.aarch64-linux.mgba-dev Hydra build #28622 of nixos-config:pr634:packages.aarch64-linux.mgba-dev
Hydra packages.aarch64-linux.fairfax-hd Hydra build #28614 of nixos-config:pr634:packages.aarch64-linux.fairfax-hd
Hydra packages.aarch64-linux.plover-plugin-machine-hid Hydra build #28633 of nixos-config:pr634:packages.aarch64-linux.plover-plugin-machine-hid
Hydra packages.x86_64-linux.mautrix-whatsapp Hydra build #28676 of nixos-config:pr634:packages.x86_64-linux.mautrix-whatsapp
Hydra packages.x86_64-linux.lotte-art Hydra build #28671 of nixos-config:pr634:packages.x86_64-linux.lotte-art
Hydra packages.aarch64-linux.emoji-volpeon-neofox Hydra build #28610 of nixos-config:pr634:packages.aarch64-linux.emoji-volpeon-neofox
Hydra packages.aarch64-linux.plover-plugin-rkb1-hid Hydra build #28636 of nixos-config:pr634:packages.aarch64-linux.plover-plugin-rkb1-hid
Hydra packages.aarch64-linux.plover-plugin-modal-dictionary Hydra build #28634 of nixos-config:pr634:packages.aarch64-linux.plover-plugin-modal-dictionary
Hydra packages.x86_64-linux.plover-plugin-machine-hid Hydra build #28688 of nixos-config:pr634:packages.x86_64-linux.plover-plugin-machine-hid
Hydra packages.aarch64-linux.plover-plugin-last-translation Hydra build #28632 of nixos-config:pr634:packages.aarch64-linux.plover-plugin-last-translation
Hydra packages.x86_64-linux.constructium Hydra build #28651 of nixos-config:pr634:packages.x86_64-linux.constructium
Hydra packages.x86_64-linux.alco-sans Hydra build #28648 of nixos-config:pr634:packages.x86_64-linux.alco-sans
Hydra packages.x86_64-linux.plover-plugin-rkb1-hid Hydra build #28691 of nixos-config:pr634:packages.x86_64-linux.plover-plugin-rkb1-hid
Hydra packages.aarch64-linux.plover-plugin-stitching Hydra build #28638 of nixos-config:pr634:packages.aarch64-linux.plover-plugin-stitching
Hydra packages.aarch64-linux.plover-plugin-yaml-dictionary Hydra build #28640 of nixos-config:pr634:packages.aarch64-linux.plover-plugin-yaml-dictionary
Hydra packages.x86_64-linux.emoji-volpeon-floof Hydra build #28661 of nixos-config:pr634:packages.x86_64-linux.emoji-volpeon-floof
Hydra packages.aarch64-linux.emoji-volpeon-neocat Hydra build #28609 of nixos-config:pr634:packages.aarch64-linux.emoji-volpeon-neocat
Hydra packages.x86_64-linux.emoji-volpeon-raccoon Hydra build #28666 of nixos-config:pr634:packages.x86_64-linux.emoji-volpeon-raccoon
Hydra packages.aarch64-linux.emoji-volpeon-drgn Hydra build #28605 of nixos-config:pr634:packages.aarch64-linux.emoji-volpeon-drgn
Hydra packages.x86_64-linux.fairfax Hydra build #28668 of nixos-config:pr634:packages.x86_64-linux.fairfax
Hydra instance-20221213-1915.aarch64-linux Hydra build #28590 of nixos-config:pr634:instance-20221213-1915.aarch64-linux
Hydra packages.x86_64-linux.plover-plugin-last-translation Hydra build #28687 of nixos-config:pr634:packages.x86_64-linux.plover-plugin-last-translation
Hydra packages.x86_64-linux.emoji-volpeon-gphn Hydra build #28663 of nixos-config:pr634:packages.x86_64-linux.emoji-volpeon-gphn
Hydra packages.aarch64-linux.python-tulir-telethon Hydra build #28646 of nixos-config:pr634:packages.aarch64-linux.python-tulir-telethon
Hydra packages.x86_64-linux.plover Hydra build #28681 of nixos-config:pr634:packages.x86_64-linux.plover
Hydra packages.aarch64-linux.kreative-square Hydra build #28615 of nixos-config:pr634:packages.aarch64-linux.kreative-square
Hydra packages.x86_64-linux.plover-plugin-modal-dictionary Hydra build #28689 of nixos-config:pr634:packages.x86_64-linux.plover-plugin-modal-dictionary
Hydra packages.aarch64-linux.emoji-volpeon-raccoon Hydra build #28611 of nixos-config:pr634:packages.aarch64-linux.emoji-volpeon-raccoon
Hydra packages.aarch64-linux.python-plover-stroke Hydra build #28643 of nixos-config:pr634:packages.aarch64-linux.python-plover-stroke
Hydra packages.x86_64-linux.python-mautrix Hydra build #28697 of nixos-config:pr634:packages.x86_64-linux.python-mautrix
Hydra packages.aarch64-linux.mautrix-telegram Hydra build #28620 of nixos-config:pr634:packages.aarch64-linux.mautrix-telegram
Hydra packages.aarch64-linux.asar-asm Hydra build #28594 of nixos-config:pr634:packages.aarch64-linux.asar-asm
Hydra packages.aarch64-linux.emoji-volpeon-bunhd Hydra build #28603 of nixos-config:pr634:packages.aarch64-linux.emoji-volpeon-bunhd
Hydra packages.aarch64-linux.plover-plugin-tapey-tape Hydra build #28639 of nixos-config:pr634:packages.aarch64-linux.plover-plugin-tapey-tape
Hydra packages.x86_64-linux.emoji-volpeon-blobfox Hydra build #28656 of nixos-config:pr634:packages.x86_64-linux.emoji-volpeon-blobfox
Hydra packages.aarch64-linux.yiffstash Hydra build #28647 of nixos-config:pr634:packages.aarch64-linux.yiffstash
Hydra packages.aarch64-linux.emoji-lotte Hydra build #28598 of nixos-config:pr634:packages.aarch64-linux.emoji-lotte
Hydra packages.x86_64-linux.python-simplefuzzyset Hydra build #28700 of nixos-config:pr634:packages.x86_64-linux.python-simplefuzzyset
Hydra packages.x86_64-linux.bsnes-plus Hydra build #28650 of nixos-config:pr634:packages.x86_64-linux.bsnes-plus
Hydra packages.aarch64-linux.matrix-media-repo Hydra build #28617 of nixos-config:pr634:packages.aarch64-linux.matrix-media-repo
Hydra packages.aarch64-linux.plover-plugin-stenotype-extended Hydra build #28637 of nixos-config:pr634:packages.aarch64-linux.plover-plugin-stenotype-extended
Hydra packages.aarch64-linux.emoji-volpeon-fox Hydra build #28607 of nixos-config:pr634:packages.aarch64-linux.emoji-volpeon-fox
Hydra packages.x86_64-linux.plover-plugin-stitching Hydra build #28693 of nixos-config:pr634:packages.x86_64-linux.plover-plugin-stitching
Hydra packages.aarch64-linux.plover-dict-didoesdigital Hydra build #28627 of nixos-config:pr634:packages.aarch64-linux.plover-dict-didoesdigital
Hydra packages.x86_64-linux.plover-plugin-python-dictionary Hydra build #28690 of nixos-config:pr634:packages.x86_64-linux.plover-plugin-python-dictionary
Hydra packages.x86_64-linux.plover-dict-didoesdigital Hydra build #28682 of nixos-config:pr634:packages.x86_64-linux.plover-dict-didoesdigital
Hydra packages.x86_64-linux.plover-plugin-emoji Hydra build #28685 of nixos-config:pr634:packages.x86_64-linux.plover-plugin-emoji
Hydra packages.x86_64-linux.plover-plugins-manager Hydra build #28696 of nixos-config:pr634:packages.x86_64-linux.plover-plugins-manager
Hydra packages.aarch64-linux.fairfax Hydra build #28613 of nixos-config:pr634:packages.aarch64-linux.fairfax
Hydra packages.x86_64-linux.python-rtf-tokenize Hydra build #28699 of nixos-config:pr634:packages.x86_64-linux.python-rtf-tokenize
Hydra packages.x86_64-linux.python-plover-stroke Hydra build #28698 of nixos-config:pr634:packages.x86_64-linux.python-plover-stroke
Hydra packages.aarch64-linux.emoji-volpeon-blobfox Hydra build #28601 of nixos-config:pr634:packages.aarch64-linux.emoji-volpeon-blobfox
Hydra packages.aarch64-linux.constructium Hydra build #28596 of nixos-config:pr634:packages.aarch64-linux.constructium
Hydra packages.x86_64-linux.plover-plugin-tapey-tape Hydra build #28694 of nixos-config:pr634:packages.x86_64-linux.plover-plugin-tapey-tape
Hydra packages.x86_64-linux.miifox-net Hydra build #28678 of nixos-config:pr634:packages.x86_64-linux.miifox-net
Hydra packages.aarch64-linux.nasin-nanpa Hydra build #28624 of nixos-config:pr634:packages.aarch64-linux.nasin-nanpa
Hydra packages.x86_64-linux.yiffstash Hydra build #28702 of nixos-config:pr634:packages.x86_64-linux.yiffstash
Hydra packages.aarch64-linux.emoji-raccoon Hydra build #28599 of nixos-config:pr634:packages.aarch64-linux.emoji-raccoon
Hydra packages.x86_64-linux.emoji-volpeon-bunhd-flip Hydra build #28659 of nixos-config:pr634:packages.x86_64-linux.emoji-volpeon-bunhd-flip

This commit is contained in:
Charlotte 🦝 Delenk 2024-12-01 09:48:07 +01:00
parent b5e2ba6526
commit 2518c5e3b0
Signed by: darkkirb
GPG key ID: AB2BD8DAF2E37122
2 changed files with 107 additions and 23 deletions

View file

@ -5,8 +5,10 @@
config,
pkgs,
hydra,
nix-eval-jobs,
...
}: let
}:
let
machines = pkgs.writeText "machines" ''
localhost armv7l-linux,powerpc-linux,powerpc64-linux,powerpc64le-linux,wasm32-wasi,x86_64-linux,i686-linux,riscv32-linux,riscv64-linux - 12 1 kvm,nixos-test,big-parallel,benchmark,gccarch-znver1,gccarch-skylake,ca-derivations -
build-aarch64 aarch64-linux,riscv32-linux,riscv64-linux - 4 1 nixos-test,benchmark,ca-derivations,gccarch-armv8-a,gccarch-armv8.1-a,gccarch-armv8.2-a,big-parallel -
@ -49,7 +51,22 @@
ControlPath ~/.ssh/master-%r@%n:%p
ControlPersist 10m
'';
in {
nix-eval-jobs-script = pkgs.stdenvNoCC.mkDerivation {
name = "remote-eval-jobs.py";
src = ./hydra/remote-eval-jobs.py;
dontUnpack = true;
dontBuild = true;
installPhase = ''
substitute $src $out \
--subst-var-by python3 ${pkgs.python3}/bin/python3
--subst-var-by ping ${pkgs.iputils}/bin/ping
--subst-var-by nix-eval-jobs ${pkgs.nix-eval-jobs}/bin/nix-eval-jobs
--subst-var-by nix ${pkgs.nix}/bin/nix
--subst-var-by ssh ${pkgs.openssh}/bin/ssh
'';
};
in
{
imports = [
./postgres.nix
../../modules/hydra.nix
@ -63,18 +80,20 @@ in {
package = hydra.packages.${system}.hydra.overrideAttrs (super: {
doCheck = false;
doInstallCheck = false;
patches =
super.patches
or []
++ [
./hydra/0001-add-gitea-pulls.patch
./hydra/0002-unlimit-output.patch
./hydra/0003-remove-pr-number-from-github-job-name.patch
./hydra/0004-use-pulls-instead-of-issues.patch
./hydra/0005-only-list-open-prs.patch
./hydra/0006-status-state.patch
./hydra/0007-hydra-server-findLog-fix-issue-with-ca-derivations-e.patch
];
patches = super.patches or [ ] ++ [
./hydra/0001-add-gitea-pulls.patch
./hydra/0002-unlimit-output.patch
./hydra/0003-remove-pr-number-from-github-job-name.patch
./hydra/0004-use-pulls-instead-of-issues.patch
./hydra/0005-only-list-open-prs.patch
./hydra/0006-status-state.patch
./hydra/0007-hydra-server-findLog-fix-issue-with-ca-derivations-e.patch
];
postPatch =
super.postPatch or ""
+ ''
substituteInPlace src/script/hydra-eval-jobset --replace-fail nix-eval-jobs ${nix-eval-jobs-script}
'';
});
hydraURL = "https://hydra.chir.rs/";
notificationSender = "hydra@chir.rs";
@ -114,9 +133,13 @@ in {
"/run/hydra-machines"
];
};
nix.settings.allowed-uris = ["github:" "https://" "http://"];
sops.secrets."services/hydra/gitea_token" = {};
sops.secrets."services/hydra/github_token" = {};
nix.settings.allowed-uris = [
"github:"
"https://"
"http://"
];
sops.secrets."services/hydra/gitea_token" = { };
sops.secrets."services/hydra/github_token" = { };
sops.secrets."services/hydra/cache-key" = {
owner = "hydra-www";
mode = "0440";
@ -135,7 +158,7 @@ in {
sops.secrets."services/hydra/aws_credentials" = {
owner = "hydra-queue-runner";
path = "/var/lib/hydra/queue-runner/.aws/credentials";
restartUnits = ["hydra-notify.service"];
restartUnits = [ "hydra-notify.service" ];
};
systemd.services.update-hydra-hosts = {
description = "Update hydra hosts";
@ -153,21 +176,21 @@ in {
systemd.timers.update-hydra-hosts = {
enable = true;
description = "Update hydra hosts";
requires = ["update-hydra-hosts.service"];
wantedBy = ["multi-user.target"];
requires = [ "update-hydra-hosts.service" ];
wantedBy = [ "multi-user.target" ];
timerConfig = {
OnBootSec = 300;
OnUnitActiveSec = 300;
};
};
nix.settings.trusted-users = ["@hydra"];
nix.settings.trusted-users = [ "@hydra" ];
sops.secrets."hydra/ssh/builder_id_ed25519" = {
sopsFile = ../../secrets/shared.yaml;
owner = "hydra-queue-runner";
key = "ssh/builder_id_ed25519";
path = "/var/lib/hydra/queue-runner/.ssh/builder_id_ed25519";
};
system.activationScripts.setupHydraSshConfig = lib.stringAfter ["var"] ''
system.activationScripts.setupHydraSshConfig = lib.stringAfter [ "var" ] ''
mkdir -p /var/lib/hydra/queue-runner/.ssh/
chown -Rv hydra-queue-runner /var/lib/hydra/queue-runner
ln -svf ${sshConfig} /var/lib/hydra/queue-runner/.ssh/config
@ -189,7 +212,7 @@ in {
systemd.services."attic-queue" = {
description = "Upload build results";
wantedBy = ["multi-user.target"];
wantedBy = [ "multi-user.target" ];
serviceConfig = {
User = "hydra-queue-runner";
Group = "hydra";

View file

@ -0,0 +1,61 @@
#!@python3@
import sys
import subprocess
import os
import json
# First check if the server is up
if subprocess.call(["@ping@", "-c", "1", "rainbow-resort.int.chir.rs"], stdout=subprocess.DEVNULL).returncode != 0:
os.execv("@nix-eval-jobs@", ["@nix-eval-jobs@"] + sys.argv[1:])
inputs_to_copy = set()
remote_args = []
skip_next = 0
next_to_copy = False
next_to_gcroots = False
gcroots = None
# parse arguments and add them to a list
for arg in sys.argv[1:]:
if arg == "--gc-roots-dir" or arg == "--max-jobs" or arg == "--workers":
skip_next = 2
if arg == "--gc-roots-dir":
next_to_gcroots = True
if next_to_gcroots:
next_to_gcroots = false
gcroots = arg
if skip_next > 0:
skip_next -= 1
continue
if next_to_copy:
inputs_to_copy.add('='.join(arg.split('=')[1:]))
next_to_copy = False
if arg == "-I":
next_to_copy = True
remote_args.append(arg)
remote_args += ["--workers" "4"]
# copy over what files we need to ensure are present on the target
subprocess.call(["@nix@", "copy"] + list(inputs_to_copy) + ["--to", "ssh://build-rainbow-resort", "--no-check-sigs"], check=True, stdout=subprocess.DEVNULL)
# Evaluate on target
result = subprocess.call(["@ssh@", "build-rainbow-resort", "nix-eval-jobs"] + remote_args, check=True, stdout=subprocess.PIPE, text=True)
for line in result.stdout:
try:
data = json.loads(line)
# copy .drv file home
subprocess.call(["@nix@", "copy", data["drvPath"], "--from", "ssh://build-rainbow-resort", "--no-check-sigs"], check=True, stdout=subprocess.DEVNULL)
# if we have a gcroot, add it to it
if gcroots is not None:
drvBasename = os.path.basename(data["drvPath"])
os.symlink(data["drvPath"], os.path.join(gcroots, drvBasename))
# Now we are done with this job, we can tell hydra about it
print(line)
except e:
print(e, file=sys.stderr)