Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
3acf40f
chore: add ADR to point out why we're doing this.
gilescope Feb 25, 2026
36f39f4
feat: save images by content hash not git hash
gilescope Feb 25, 2026
cfff893
Merge branch 'main' into giles-content-hashes
gilescope Feb 25, 2026
0af4765
fix: less shellcheck errors
gilescope Feb 27, 2026
3044487
Merge branch 'main' into giles-content-hashes
gilescope Feb 28, 2026
f912400
Merge branch 'main' into giles-content-hashes
gilescope Feb 28, 2026
2c55ed4
Merge branch 'main' into giles-content-hashes
gilescope Mar 6, 2026
6b6c9c4
fix: was accidentally rebuilding ci image rather than refering to pre…
gilescope Mar 5, 2026
4343720
fix: shellcheck
gilescope Mar 7, 2026
00c8917
Merge branch 'main' into giles-content-hashes
gilescope Mar 7, 2026
edcb01c
fix: use content hash everywhere.
gilescope Mar 7, 2026
c16e2cd
fix: reuse toolkit rather than rebuild it
gilescope Mar 7, 2026
73720e9
Merge branch 'main' into giles-content-hashes
gilescope Mar 7, 2026
927a00e
feat: indexer rarely changes
gilescope Mar 7, 2026
211767f
feat: skip rebuilding hardfork images if nothing changed.
gilescope Mar 7, 2026
b0abce3
fix: don't run check if you've already built image.
gilescope Mar 7, 2026
e140c83
fix: trade runtime speed for better compile times on tests
gilescope Mar 7, 2026
a3aae8c
try: cranelift for faster testing
gilescope Mar 7, 2026
4fe75d9
try: cranelift for faster testing (test-pallet-fixtures)
gilescope Mar 7, 2026
2f318ff
try: cranelift for faster toolkit-testing
gilescope Mar 8, 2026
f06eb56
chore: fmt
gilescope Mar 8, 2026
39926ca
feat: pull out feature unification check into own workflow
gilescope Mar 8, 2026
cbe337e
feat: pull out feature unification check into own workflow
gilescope Mar 8, 2026
696c653
feat: undo cranelift for now
gilescope Mar 9, 2026
bf06cd8
feat: still tag using prev commit tags.
gilescope Mar 16, 2026
5db6eee
feat: embed the content hash in the image as an env var
gilescope Mar 16, 2026
1a8a7e1
Merge branch 'main' into giles-content-hashes
gilescope Mar 17, 2026
b2db443
Merge branch 'main' into giles-content-hashes
gilescope Mar 18, 2026
e24c6eb
Merge branch 'main' into giles-content-hashes
gilescope Mar 18, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
82 changes: 78 additions & 4 deletions .github/workflows/continuous-integration-checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,21 +21,95 @@ jobs:
env:
FORCE_COLOR: 1
steps:
- name: Checkout node repository
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd #v6.0.2

- name: Merge Conflict Finder
uses: olivernybroe/action-conflict-finder@78f7add155e0bf97e9c71cb0383ef5691f72868c # v4.0

- name: Login to GHCR
uses: docker/login-action@c94ce9fb468520275223c153574b00df6fe4bcc9 #v3.7.0
with:
registry: ghcr.io
username: MidnightCI
password: ${{ secrets.MIDNIGHTCI_PACKAGES_READ }}

- name: Check for existing images
id: check_images
run: |
content_hash=$(git rev-parse "HEAD^{tree}" | cut -c1-12)
version=$(grep -m 1 '^version =' node/Cargo.toml | cut -d '"' -f2)
tag="${version}-dev-${content_hash}-amd64"
NODE_EXISTS=$(docker manifest inspect "ghcr.io/midnight-ntwrk/midnight-node:${tag}" > /dev/null 2>&1 && echo true || echo false)
TOOLKIT_EXISTS=$(docker manifest inspect "ghcr.io/midnight-ntwrk/midnight-node-toolkit:${version}-${content_hash}-amd64" > /dev/null 2>&1 && echo true || echo false)
if [ "$NODE_EXISTS" = "true" ] && [ "$TOOLKIT_EXISTS" = "true" ]; then
echo "skip_check=true" >> "$GITHUB_OUTPUT"
echo "Images already exist, skipping format/lint check"
else
echo "skip_check=false" >> "$GITHUB_OUTPUT"
fi

- uses: EarthBuild/actions-setup@cae2d9ab68894d8402751fe42e07c7cca0272f7f
if: steps.check_images.outputs.skip_check != 'true'
with:
version: v0.8.16
github-token: ${{ github.token }}
use-cache: false

- name: Free disk space
if: steps.check_images.outputs.skip_check != 'true'
run: scripts/free-disk-space.sh

- name: Run build
if: steps.check_images.outputs.skip_check != 'true'
run: |
. ./.envrc && earthly --ci +check

feature-unification:
name: Feature Unification Check
runs-on: ubuntu-latest
permissions:
contents: read
env:
FORCE_COLOR: 1
steps:
- name: Checkout node repository
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd #v6.0.2

- name: Merge Conflict Finder
uses: olivernybroe/action-conflict-finder@78f7add155e0bf97e9c71cb0383ef5691f72868c # v4.0
- name: Login to GHCR
uses: docker/login-action@c94ce9fb468520275223c153574b00df6fe4bcc9 #v3.7.0
with:
registry: ghcr.io
username: MidnightCI
password: ${{ secrets.MIDNIGHTCI_PACKAGES_READ }}

- name: Check for existing images
id: check_images
run: |
content_hash=$(git rev-parse "HEAD^{tree}" | cut -c1-12)
version=$(grep -m 1 '^version =' node/Cargo.toml | cut -d '"' -f2)
tag="${version}-dev-${content_hash}-amd64"
NODE_EXISTS=$(docker manifest inspect "ghcr.io/midnight-ntwrk/midnight-node:${tag}" > /dev/null 2>&1 && echo true || echo false)
TOOLKIT_EXISTS=$(docker manifest inspect "ghcr.io/midnight-ntwrk/midnight-node-toolkit:${version}-${content_hash}-amd64" > /dev/null 2>&1 && echo true || echo false)
if [ "$NODE_EXISTS" = "true" ] && [ "$TOOLKIT_EXISTS" = "true" ]; then
echo "skip_check=true" >> "$GITHUB_OUTPUT"
echo "Images already exist, skipping feature unification check"
else
echo "skip_check=false" >> "$GITHUB_OUTPUT"
fi

- uses: EarthBuild/actions-setup@cae2d9ab68894d8402751fe42e07c7cca0272f7f
if: steps.check_images.outputs.skip_check != 'true'
with:
version: v0.8.16
github-token: ${{ github.token }}
use-cache: false

- name: Free disk space
if: steps.check_images.outputs.skip_check != 'true'
run: scripts/free-disk-space.sh

- name: Run build
- name: Run feature unification check
if: steps.check_images.outputs.skip_check != 'true'
run: |
. ./.envrc && earthly --ci +check
. ./.envrc && earthly --ci +check-feature-unification
Loading
Loading