Skip to content

Commit c6ff786

Browse files
committed
Swap garnix for cachix
Substituters in both flakes now point at argumentcomputer.cachix.org, and a GitHub Actions workflow replaces garnix as the cache populator: it builds each package and realizes the dev shell (with a cargo-zisk --version smoke test), pushing store paths via cachix-action. The packages garnix.yaml excluded (install-proving-key, build-image, run-zisk, zisk-shell) are simply not built. Requires the CACHIX_AUTH_TOKEN secret and WarpBuild runners; change runs-on to ubuntu-latest if the latter aren't enabled for this repo.
1 parent 6811311 commit c6ff786

4 files changed

Lines changed: 43 additions & 10 deletions

File tree

.github/workflows/nix.yml

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
name: Nix CI
2+
3+
on:
4+
push:
5+
branches: main
6+
pull_request:
7+
workflow_dispatch:
8+
9+
permissions:
10+
contents: read
11+
12+
concurrency:
13+
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
14+
cancel-in-progress: true
15+
16+
jobs:
17+
nix-build:
18+
name: Nix Build
19+
runs-on: warp-ubuntu-latest-x64-8x
20+
steps:
21+
- uses: actions/checkout@v6
22+
- uses: cachix/install-nix-action@v31
23+
with:
24+
nix_path: nixpkgs=channel:nixos-unstable
25+
github_access_token: ${{ secrets.GITHUB_TOKEN }}
26+
- uses: cachix/cachix-action@v16
27+
with:
28+
name: argumentcomputer
29+
authToken: ${{ secrets.CACHIX_AUTH_TOKEN }}
30+
# One step per package for separate logs; the store is shared across
31+
# steps, so nothing rebuilds.
32+
- run: nix build --print-build-logs --accept-flake-config .#cargo-zisk
33+
- run: nix build --print-build-logs --accept-flake-config .#ziskemu
34+
- run: nix build --print-build-logs --accept-flake-config .#zisk-home
35+
- run: nix build --print-build-logs --accept-flake-config .#zisk-toolchain
36+
- run: nix build --print-build-logs --accept-flake-config .#rustup-shim
37+
# Realize the dev shell so it's verified and pushed to the cache,
38+
# and smoke-test the toolchain entrypoint.
39+
- run: nix develop --print-build-logs --accept-flake-config --command cargo-zisk --version

flake.nix

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,10 @@
33

44
nixConfig = {
55
extra-substituters = [
6-
"https://cache.garnix.io"
6+
"https://argumentcomputer.cachix.org"
77
];
88
extra-trusted-public-keys = [
9-
"cache.garnix.io:CTFPyKSLcx5RMJKfLo5EEPUObbA78b0YQ2DTCJXqr9g="
9+
"argumentcomputer.cachix.org-1:ovhbTx1V56BYDerOWInQvXKXl68LlhNwEA+n7EWk1m4="
1010
];
1111
};
1212

garnix.yaml

Lines changed: 0 additions & 6 deletions
This file was deleted.

templates/sha_hasher/flake.nix

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,10 @@
33

44
nixConfig = {
55
extra-substituters = [
6-
"https://cache.garnix.io"
6+
"https://argumentcomputer.cachix.org"
77
];
88
extra-trusted-public-keys = [
9-
"cache.garnix.io:CTFPyKSLcx5RMJKfLo5EEPUObbA78b0YQ2DTCJXqr9g="
9+
"argumentcomputer.cachix.org-1:ovhbTx1V56BYDerOWInQvXKXl68LlhNwEA+n7EWk1m4="
1010
];
1111
};
1212

0 commit comments

Comments
 (0)