11# SPDX-License-Identifier: PMPL-1.0-or-later
2+ #
3+ # container-ci.yml — Container build verification.
4+ #
5+ # Two jobs:
6+ # container-build — builds the minimal ECHIDNA image on every PR/push;
7+ # hard gate.
8+ # tier3-container — builds each Wave-3 prover image weekly (Sunday 06:00 UTC)
9+ # and on any change to the .containerization/** tree;
10+ # allow-fail per image (proprietary builds excluded).
11+
212name : Container Build Verification
313
414on :
1828 - ' Cargo.lock'
1929 - ' src/rust/**'
2030 - ' .github/workflows/container-ci.yml'
31+ schedule :
32+ # Weekly build of Tier-3 prover images (Sunday 06:00 UTC).
33+ # Distinct from live-provers.yml Tier-3 run (Sunday 05:00 UTC)
34+ # so the container build does not race the live-prover tests.
35+ - cron : ' 0 6 * * 0'
2136
22- permissions : read-all
37+ permissions :
38+ contents : read
2339
2440jobs :
41+ # ── Job 1: minimal image — hard gate on every PR/push ─────────────────────
2542 container-build :
2643 name : Build & verify container image
2744 runs-on : ubuntu-latest
45+
2846 steps :
29- - uses : actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
47+ - name : Checkout
48+ uses : actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
3049
3150 - name : Install Podman
3251 run : |
@@ -44,35 +63,118 @@ jobs:
4463 - name : Verify image metadata
4564 run : |
4665 echo "=== Image labels ==="
47- podman inspect echidna:ci-test --format '{{range $k, $v := .Config.Labels}}{{$k}}: {{$v}}{{"\n"}}{{end}}'
48-
66+ podman inspect echidna:ci-test \
67+ --format '{{range $k, $v := .Config.Labels}}{{$k}}: {{$v}}{{"\n"}}{{end}}'
4968 echo "=== Image size ==="
5069 podman images echidna:ci-test --format "{{.Size}}"
5170
5271 - name : Verify ECHIDNA binary runs
5372 run : |
5473 echo "=== echidna --version ==="
5574 podman run --rm echidna:ci-test --version
56-
5775 echo "=== echidna --help ==="
5876 podman run --rm echidna:ci-test --help
5977
6078 - name : Verify solver availability inside container
6179 run : |
6280 echo "=== Checking installed solvers ==="
6381 podman run --rm --entrypoint /bin/sh echidna:ci-test -c '
64- echo "Z3:"; z3 --version 2>/dev/null || echo " not found"
65- echo "Lean:"; lean --version 2>/dev/null || echo " not found"
82+ echo "Z3:"; z3 --version 2>/dev/null || echo " not found"
83+ echo "Lean:"; lean --version 2>/dev/null || echo " not found"
6684 echo "Idris2:"; idris2 --version 2>/dev/null || echo " not found"
6785 '
6886
69- - name : Verify healthcheck
87+ - name : Clean up
88+ if : always()
89+ run : podman rmi echidna:ci-test 2>/dev/null || true
90+
91+ # ── Job 2: Wave-3 Tier-3 prover images — weekly, allow-fail per image ─────
92+ #
93+ # Runs on the weekly schedule and whenever any .containerization/** file
94+ # changes. Each prover builds in its own matrix cell; allow-fail is set
95+ # at cell level so one broken prover does not mask the others.
96+ #
97+ # Imandra is excluded: it is proprietary and requires a licence token not
98+ # available in public CI.
99+ tier3-container :
100+ name : Tier-3 / ${{ matrix.prover }}
101+ runs-on : ubuntu-latest
102+ # Run on schedule or when the .containerization tree changes on main.
103+ # Not a merge gate — these are informational weekly builds.
104+ if : >-
105+ github.event_name == 'schedule' ||
106+ (github.event_name == 'push' && contains(github.event.head_commit.modified, '.containerization/'))
107+ continue-on-error : true
108+ strategy :
109+ fail-fast : false
110+ matrix :
111+ include :
112+ - prover : tamarin
113+ image : echidna:tamarin
114+ file : .containerization/Containerfile.tamarin
115+ version_check : " tamarin-prover --version"
116+ - prover : proverif
117+ image : echidna:proverif
118+ file : .containerization/Containerfile.proverif
119+ version_check : " proverif -help 2>&1 | head -1"
120+ - prover : metamath
121+ image : echidna:metamath
122+ file : .containerization/Containerfile.metamath
123+ version_check : " echo exit | metamath 2>&1 | head -1 || true"
124+ - prover : twelf
125+ image : " echidna:twelf"
126+ file : .containerization/Containerfile.twelf
127+ version_check : " twelf-server --help 2>&1 | head -1 || true"
128+ - prover : or-tools
129+ image : echidna:or-tools
130+ file : .containerization/Containerfile.or-tools
131+ version_check : " ls /usr/local/lib/libortools* 2>/dev/null | head -1 || true"
132+ - prover : scip
133+ image : echidna:scip
134+ file : .containerization/Containerfile.scip
135+ version_check : " scip --version 2>&1 | head -1 || true"
136+ - prover : hol4
137+ image : echidna:hol4
138+ file : .containerization/Containerfile.hol4
139+ version_check : " echo '(* quit *);' | hol 2>&1 | head -1 || true"
140+ - prover : acl2
141+ image : echidna:acl2
142+ file : .containerization/Containerfile.acl2
143+ version_check : " echo '(acl2::quit)' | acl2 2>&1 | head -3 || true"
144+
145+ steps :
146+ - name : Checkout
147+ uses : actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
148+
149+ - name : Install Podman
70150 run : |
71- echo "=== Running healthcheck command ==="
72- podman run --rm echidna:ci-test --version
73- echo "✓ Healthcheck passed"
151+ sudo apt-get update -q
152+ sudo apt-get install -y -q podman
153+
154+ - name : Build ${{ matrix.prover }} image
155+ # HOL4 and ACL2 have long build times; give them extra headroom.
156+ timeout-minutes : 90
157+ run : |
158+ podman build \
159+ -f "${{ matrix.file }}" \
160+ -t "${{ matrix.image }}" \
161+ --no-cache \
162+ .
163+
164+ - name : Verify ECHIDNA binary inside ${{ matrix.prover }} image
165+ run : |
166+ podman run --rm "${{ matrix.image }}" --version
167+
168+ - name : Smoke-check ${{ matrix.prover }} binary
169+ run : |
170+ podman run --rm --entrypoint /bin/sh "${{ matrix.image }}" \
171+ -c '${{ matrix.version_check }}'
172+
173+ - name : Verify image metadata
174+ run : |
175+ podman inspect "${{ matrix.image }}" \
176+ --format '{{index .Config.Labels "org.opencontainers.image.description"}}'
74177
75178 - name : Clean up
76179 if : always()
77- run : |
78- podman rmi echidna:ci-test 2>/dev/null || true
180+ run : podman rmi "${{ matrix.image }}" 2>/dev/null || true
0 commit comments