| @@ -38,6 +38,10 @@ check: |
| 38 | # rather than carry it as a second secret we lean on the transport -- the | 38 | # rather than carry it as a second secret we lean on the transport -- the |
| 39 | # store is reached over SSH authenticated with our own key. cache.nixos.org | 39 | # store is reached over SSH authenticated with our own key. cache.nixos.org |
| 40 | # is verified by its own key either way; require-sigs only relaxes nixbuild. | 40 | # is verified by its own key either way; require-sigs only relaxes nixbuild. |
| | 41 | + # The explicit priority matters: nix picks a substituter by priority rather |
| | 42 | + # than by the order listed here, and an ssh-ng store defaults to 0 against |
| | 43 | + # cache.nixos.org's 40, so without it nixbuild wins even for stock nixpkgs |
| | 44 | + # paths and they crawl through one SSH connection instead of the CDN. |
| 41 | # | 45 | # |
| 42 | # Keep the builder's job count modest. nixbuild's sshd caps concurrent | 46 | # Keep the builder's job count modest. nixbuild's sshd caps concurrent |
| 43 | # sessions and refuses the excess, which nix surfaces as the thoroughly | 47 | # sessions and refuses the excess, which nix surfaces as the thoroughly |
| @@ -54,7 +58,7 @@ check: |
| 54 | 'experimental-features = nix-command flakes' \ | 58 | 'experimental-features = nix-command flakes' \ |
| 55 | 'builders = ssh-ng://eu.nixbuild.net x86_64-linux - 16 1 big-parallel,benchmark' \ | 59 | 'builders = ssh-ng://eu.nixbuild.net x86_64-linux - 16 1 big-parallel,benchmark' \ |
| 56 | 'builders-use-substitutes = true' \ | 60 | 'builders-use-substitutes = true' \ |
| 57 | - 'substituters = https://cache.nixos.org ssh-ng://eu.nixbuild.net' \ | 61 | + 'substituters = https://cache.nixos.org ssh-ng://eu.nixbuild.net?priority=50' \ |
| 58 | 'require-sigs = false' \ | 62 | 'require-sigs = false' \ |
| 59 | "max-jobs = $(nproc)" >> /etc/nix/nix.conf | 63 | "max-jobs = $(nproc)" >> /etc/nix/nix.conf |
| 60 | script: | 64 | script: |