Repository navigation
98 lines (91 loc) · 3.73 KB
/
Copy pathci.yml
File metadata and controls
98 lines (91 loc) · 3.73 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
name: CI
on:
pull_request:
push:
branches: [main]
# The reusable release workflow dispatches this file on the release PR branch.
workflow_dispatch:
permissions:
contents: read
concurrency:
group: ci-${{ github.ref }}
cancel-in-progress: true
jobs:
# The @systemfsoftware tarballs the lockfile installs from, built by this
# repository's flake from its pinned systemfsoftware and stryker-js-effect
# commits. The tarballs are architecture-independent, so one build serves
# every job below.
sfs-deps:
name: systemfsoftware tarballs from the flake
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
- uses: cachix/install-nix-action@13d8dd58da0234aa297dedd986986ccb8e7f3e24 # v31.11.1
- name: Build the tarballs the lockfile names
run: cp -rL "$(nix build --no-link --print-out-paths .#sfs-deps)" .sfs-deps
- name: The lockfile's recorded integrities match the flake's tarballs
run: nix build --no-link .#checks.x86_64-linux.consumer-store
- uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
with:
name: sfs-deps
path: .sfs-deps/
retention-days: 1
include-hidden-files: true
if-no-files-found: error
# Lint, typecheck, build with attw, and the test jobs the planner packs from
# recorded timings. Each phase runs .github/actions/checks-lane.
checks:
needs: sfs-deps
permissions:
contents: read
actions: read
uses: systemfsoftware/systemfsoftware/.github/workflows/reusable-checks.yml@732f66a0c85819b2005f9e0930a595bc4de91ee1
with:
lanes: '[{"id": "lint", "name": "lint", "timeout-minutes": 10, "run": "pnpm lint"}, {"id": "typecheck", "name": "typecheck", "timeout-minutes": 10, "run": "pnpm typecheck"}, {"id": "build", "name": "build · attw", "timeout-minutes": 10, "run": "pnpm build && pnpm --filter @systemfsoftware/api-extractor attw"}]'
timeout-minutes: 10
max-seconds: 600
plan-timeout-minutes: 10
host-bytes:
name: Output bytes on ${{ matrix.arch }}
needs: sfs-deps
strategy:
matrix:
include:
- arch: x86_64
runner: ubuntu-latest
- arch: arm64
runner: ubuntu-24.04-arm
runs-on: ${{ matrix.runner }}
timeout-minutes: 10
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
- uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
with:
name: sfs-deps
path: .sfs-deps
- uses: pnpm/action-setup@ea17c68df8912ef543352723c149a84f56e3d413 # v6.1.0
- uses: actions/setup-node@949feb2413d6458794dcd2491c4babbbce0c15c1 # v7.1.0
with:
node-version: 24
cache: pnpm
- run: pnpm install --frozen-lockfile
- name: Serialise a fixed-seed sample of models and verdicts
run: node --conditions=@systemfsoftware/source apps/api-extractor-e2e/host-digest.ts > host-output.bin
- run: sha256sum host-output.bin && uname -m
- uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
with:
name: host-output-${{ matrix.arch }}
path: host-output.bin
host-compare:
name: Same bytes on every host
needs: host-bytes
runs-on: ubuntu-latest
timeout-minutes: 5
steps:
- uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
with:
pattern: host-output-*
- run: sha256sum host-output-*/host-output.bin
- name: Compare x86_64 and arm64 outputs byte for byte
run: cmp host-output-x86_64/host-output.bin host-output-arm64/host-output.bin