Skip to content
This repository was archived by the owner on Jun 6, 2025. It is now read-only.

Commit 7d3ce03

Browse files
authored
improve docker images, improve ci (#44)
* improve docker images, improve ci * improve docker images, improve ci * improve docker images, improve ci * improve docker images, improve ci * improve docker images, improve ci * improve docker images, improve ci * improve docker images, improve ci * improve docker images, improve ci * improve docker images, improve ci * improve docker images, improve ci * improve docker images, improve ci * improve docker images, improve ci * improve docker images, improve ci * improve docker images, improve ci * improve docker images, improve ci * improve docker images, improve ci * improve docker images, improve ci * improve docker images, improve ci * improve docker images, improve ci * improve docker images, improve ci * improve docker images, improve ci
1 parent 2b72b23 commit 7d3ce03

File tree

18 files changed

+342
-417
lines changed

18 files changed

+342
-417
lines changed

.github/workflows/build-check.yml

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
name: Rebuild Check image
2+
3+
on:
4+
workflow_dispatch:
5+
pull_request:
6+
paths:
7+
- 'check/**'
8+
push:
9+
branches:
10+
- master
11+
paths:
12+
- 'check/**'
13+
14+
permissions:
15+
contents: read
16+
packages: write
17+
attestations: write
18+
id-token: write
19+
20+
concurrency:
21+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
22+
cancel-in-progress: true
23+
24+
jobs:
25+
check:
26+
runs-on: ubuntu-latest
27+
steps:
28+
- name: Checkout repo
29+
uses: actions/checkout@v4
30+
- name: Set up QEMU
31+
uses: docker/setup-qemu-action@v3
32+
- name: Set up Docker Buildx
33+
uses: docker/setup-buildx-action@v3
34+
- name: Login to GHCR
35+
uses: docker/login-action@v3
36+
with:
37+
registry: us-central1-docker.pkg.dev/molten-verve-216720/heliax-repository
38+
username: _json_key
39+
password: ${{ secrets.ANTITHESIS_GAR_JSON_KEY }}
40+
- name: Login to ghcr.io
41+
uses: docker/login-action@v3
42+
with:
43+
registry: ghcr.io
44+
username: ${{ github.actor }}
45+
password: ${{ secrets.GITHUB_TOKEN }}
46+
- name: Build and push
47+
uses: docker/build-push-action@v6
48+
with:
49+
context: check
50+
push: ${{ github.event_name != 'pull_request' }}
51+
tags: |
52+
ghcr.io/heliaxdev/ant-check:latest
53+
us-central1-docker.pkg.dev/molten-verve-216720/heliax-repository/check:latest
54+
cache-from: type=gha,scope=check-image
55+
cache-to: type=gha,scope=check-image,mode=max

.github/workflows/build-masp.yml

Lines changed: 44 additions & 74 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,24 @@
1-
name: Rebuild MASP indexer images (triggerable)
1+
name: Rebuild MASP indexer images
22

33
on:
44
workflow_dispatch:
55
inputs:
6-
masp_commit:
7-
description: "The namada masp indexer SHA commit to build"
6+
tag:
7+
description: "The container tag"
88
required: true
99
type: string
10+
pull_request:
11+
paths:
12+
- 'masp-indexer/**'
13+
push:
14+
branches:
15+
- master
16+
paths:
17+
- 'masp-indexer/**'
18+
19+
concurrency:
20+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
21+
cancel-in-progress: true
1022

1123
permissions:
1224
contents: read
@@ -15,41 +27,25 @@ permissions:
1527
id-token: write
1628

1729
jobs:
18-
masp-indexer-webserver:
19-
runs-on: ubuntu-latest
20-
env:
21-
antithesis_registry_url: us-central1-docker.pkg.dev/molten-verve-216720/heliax-repository
22-
steps:
23-
- name: Checkout repo
24-
uses: actions/checkout@v4
25-
- name: Set up QEMU
26-
uses: docker/setup-qemu-action@v3
27-
- name: Set up Docker Buildx
28-
uses: docker/setup-buildx-action@v3
29-
- name: Login to GHCR
30-
uses: docker/login-action@v3
31-
with:
32-
registry: ${{ env.antithesis_registry_url }}
33-
username: _json_key
34-
password: ${{ secrets.ANTITHESIS_GAR_JSON_KEY }}
35-
- name: Login to ghcr.io
36-
uses: docker/login-action@v3
37-
with:
38-
registry: ghcr.io
39-
username: ${{ github.actor }}
40-
password: ${{ secrets.GITHUB_TOKEN }}
41-
- name: Build & Push Image Masp Indexer Webserver
42-
run: |
43-
registry_url="${{ env.antithesis_registry_url }}" masp_sha=${{ github.event.inputs.masp_commit }} make build-masp-indexer-webserver
44-
docker push ${{ env.antithesis_registry_url }}/masp-indexer-webserver:${{ github.event.inputs.masp_commit }}
45-
46-
docker tag ${{ env.antithesis_registry_url }}/masp-indexer-webserver:${{ github.event.inputs.masp_commit }} ghcr.io/heliaxdev/ant-masp-indexer-webserver:${{ github.event.inputs.masp_commit }}
47-
docker push ghcr.io/heliaxdev/ant-masp-indexer-webserver:${{ github.event.inputs.masp_commit }}
30+
masp-indexer:
31+
strategy:
32+
fail-fast: true
33+
matrix:
34+
images:
35+
- name: "masp-indexer-webserver"
36+
context: "masp-indexer/webserver"
37+
sha: "master"
38+
cache_scope: "masp-indexer-webserver-image"
39+
- name: "masp-indexer-chain"
40+
context: "masp-indexer/chain"
41+
sha: "master"
42+
cache_scope: "masp-indexer-chain-image"
43+
- name: "masp-indexer-block-filter"
44+
context: "masp-indexer/block-filter"
45+
sha: "master"
46+
cache_scope: "masp-indexer-block-filter-image"
4847

49-
masp-indexer-chain:
5048
runs-on: ubuntu-latest
51-
env:
52-
antithesis_registry_url: us-central1-docker.pkg.dev/molten-verve-216720/heliax-repository
5349
steps:
5450
- name: Checkout repo
5551
uses: actions/checkout@v4
@@ -60,7 +56,7 @@ jobs:
6056
- name: Login to GHCR
6157
uses: docker/login-action@v3
6258
with:
63-
registry: ${{ env.antithesis_registry_url }}
59+
registry: us-central1-docker.pkg.dev/molten-verve-216720/heliax-repository
6460
username: _json_key
6561
password: ${{ secrets.ANTITHESIS_GAR_JSON_KEY }}
6662
- name: Login to ghcr.io
@@ -69,41 +65,15 @@ jobs:
6965
registry: ghcr.io
7066
username: ${{ github.actor }}
7167
password: ${{ secrets.GITHUB_TOKEN }}
72-
- name: Build & Push Image Masp Indexer Chain
73-
run: |
74-
registry_url="${{ env.antithesis_registry_url }}" masp_sha=${{ github.event.inputs.masp_commit }} make build-masp-indexer-chain
75-
docker push ${{ env.antithesis_registry_url }}/masp-indexer-chain:${{ github.event.inputs.masp_commit }}
76-
77-
docker tag ${{ env.antithesis_registry_url }}/masp-indexer-chain:${{ github.event.inputs.masp_commit }} ghcr.io/heliaxdev/ant-masp-indexer-chain:${{ github.event.inputs.masp_commit }}
78-
docker push ghcr.io/heliaxdev/ant-masp-indexer-chain:${{ github.event.inputs.masp_commit }}
79-
80-
masp-indexer-block-filter:
81-
runs-on: ubuntu-latest
82-
env:
83-
antithesis_registry_url: us-central1-docker.pkg.dev/molten-verve-216720/heliax-repository
84-
steps:
85-
- name: Checkout repo
86-
uses: actions/checkout@v4
87-
- name: Set up QEMU
88-
uses: docker/setup-qemu-action@v3
89-
- name: Set up Docker Buildx
90-
uses: docker/setup-buildx-action@v3
91-
- name: Login to GHCR
92-
uses: docker/login-action@v3
93-
with:
94-
registry: ${{ env.antithesis_registry_url }}
95-
username: _json_key
96-
password: ${{ secrets.ANTITHESIS_GAR_JSON_KEY }}
97-
- name: Login to ghcr.io
98-
uses: docker/login-action@v3
68+
- name: Build and push
69+
uses: docker/build-push-action@v6
9970
with:
100-
registry: ghcr.io
101-
username: ${{ github.actor }}
102-
password: ${{ secrets.GITHUB_TOKEN }}
103-
- name: Build & Push Image Masp Indexer Block Filter
104-
run: |
105-
registry_url="${{ env.antithesis_registry_url }}" masp_sha=${{ github.event.inputs.masp_commit }} make build-masp-indexer-block-filter
106-
docker push ${{ env.antithesis_registry_url }}/masp-indexer-block-filter:${{ github.event.inputs.masp_commit }}
107-
108-
docker tag ${{ env.antithesis_registry_url }}/masp-indexer-block-filter:${{ github.event.inputs.masp_commit }} ghcr.io/heliaxdev/ant-masp-indexer-block-filter:${{ github.event.inputs.masp_commit }}
109-
docker push ghcr.io/heliaxdev/ant-masp-indexer-block-filter:${{ github.event.inputs.masp_commit }}
71+
context: ${{ matrix.images.context }}
72+
push: ${{ github.event_name != 'pull_request' }}
73+
tags: |
74+
ghcr.io/heliaxdev/ant-${{ matrix.images.name }}:${{ github.event.inputs.tag || github.sha }}
75+
us-central1-docker.pkg.dev/molten-verve-216720/heliax-repository/${{ matrix.images.name }}:${{ github.event.inputs.tag || github.sha }}
76+
cache-from: type=gha,scope=${{ matrix.images.cache_scope }}
77+
cache-to: type=gha,scope=${{ matrix.images.cache_scope }},mode=max
78+
build-args: |
79+
GIT_SHA=${{ matrix.images.sha || 'master' }}

.github/workflows/build-namada.yml

Lines changed: 35 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Rebuild Namada images (triggerable)
1+
name: Rebuild Namada images
22

33
on:
44
workflow_dispatch:
@@ -11,6 +11,17 @@ on:
1111
description: "The genesis template version"
1212
required: true
1313
type: string
14+
schedule:
15+
- cron: "0 20 * * *"
16+
pull_request:
17+
paths:
18+
- 'config/**'
19+
- 'namada/**'
20+
- 'genesis/**'
21+
22+
concurrency:
23+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
24+
cancel-in-progress: true
1425

1526
permissions:
1627
contents: read
@@ -19,26 +30,29 @@ permissions:
1930
id-token: write
2031

2132
jobs:
22-
docker:
33+
namada:
2334
runs-on: ubuntu-latest
2435
env:
2536
antithesis_registry_url: us-central1-docker.pkg.dev/molten-verve-216720/heliax-repository
2637
strategy:
2738
fail-fast: true
2839
matrix:
2940
images:
30-
- make: "build-config"
41+
- context: "config"
3142
image: "namada-config"
32-
tag: ""
33-
- make: "build-genesis"
43+
tag: "config-scope"
44+
- context: "genesis"
45+
cache_scope: "genesis-image"
3446
image: "namada-genesis"
3547
tag: ""
36-
- make: "build-namada"
37-
image: "namada"
48+
- image: "namada"
49+
cache_scope: "namada-image"
3850
tag: ""
39-
- make: "build-namada-inst"
40-
image: "namada"
51+
context: "namada"
52+
- image: "namada"
4153
tag: -inst
54+
context: "namada"
55+
cache_scope: "namada-inst-image"
4256

4357
steps:
4458
- name: Checkout repo
@@ -59,41 +73,16 @@ jobs:
5973
registry: ghcr.io
6074
username: ${{ github.actor }}
6175
password: ${{ secrets.GITHUB_TOKEN }}
62-
- name: Build & Push Image ${{ matrix.images.image }} with sha commit ${{ github.event.inputs.commit }}/${{ github.event.inputs.genesis_template_version }}
63-
run: |
64-
registry_url="${{ env.antithesis_registry_url }}" sha=${{ github.event.inputs.commit }} genesis_template_version=${{ github.event.inputs.genesis_template_version }} make ${{ matrix.images.make }}
65-
docker push ${{ env.antithesis_registry_url }}/${{ matrix.images.image }}:${{ github.event.inputs.commit }}${{ matrix.images.tag }}
66-
67-
docker tag ${{ env.antithesis_registry_url }}/${{ matrix.images.image }}:${{ github.event.inputs.commit }}${{ matrix.images.tag }} ghcr.io/heliaxdev/ant-${{ matrix.images.image }}:${{ github.event.inputs.commit }}${{ matrix.images.tag }}
68-
docker push ghcr.io/heliaxdev/ant-${{ matrix.images.image }}:${{ github.event.inputs.commit }}${{ matrix.images.tag }}
69-
70-
check-container:
71-
runs-on: ubuntu-latest
72-
env:
73-
antithesis_registry_url: us-central1-docker.pkg.dev/molten-verve-216720/heliax-repository
74-
steps:
75-
- name: Checkout repo
76-
uses: actions/checkout@v4
77-
- name: Set up QEMU
78-
uses: docker/setup-qemu-action@v3
79-
- name: Set up Docker Buildx
80-
uses: docker/setup-buildx-action@v3
81-
- name: Login to GHCR
82-
uses: docker/login-action@v3
76+
- name: Build & Push Image ${{ matrix.images.image }} with sha commit ${{ github.event.inputs.commit || 'main' }}/${{ github.event.inputs.genesis_template_version || '0.46.0-ant' }}
77+
uses: docker/build-push-action@v6
8378
with:
84-
registry: ${{ env.antithesis_registry_url }}
85-
username: _json_key
86-
password: ${{ secrets.ANTITHESIS_GAR_JSON_KEY }}
87-
- name: Login to ghcr.io
88-
uses: docker/login-action@v3
89-
with:
90-
registry: ghcr.io
91-
username: ${{ github.actor }}
92-
password: ${{ secrets.GITHUB_TOKEN }}
93-
- name: Build & Push Image Check Container
94-
run: |
95-
registry_url="${{ env.antithesis_registry_url }}" make build-check
96-
docker push ${{ env.antithesis_registry_url }}/check:latest
97-
98-
docker tag ${{ env.antithesis_registry_url }}/check:latest ghcr.io/heliaxdev/ant-check:latest
99-
docker push ghcr.io/heliaxdev/ant-check:latest
79+
context: ${{ matrix.images.context }}
80+
push: ${{ github.event_name != 'pull_request' }}
81+
tags: |
82+
ghcr.io/heliaxdev/ant-${{ matrix.images.image }}:${{ github.event.inputs.tag || github.sha }}${{ matrix.images.tag }}
83+
us-central1-docker.pkg.dev/molten-verve-216720/heliax-repository/${{ matrix.images.image }}:${{ github.event.inputs.tag || github.sha }}${{ matrix.images.tag }}
84+
cache-from: type=gha,scope=${{ matrix.images.cache_scope }}
85+
cache-to: type=gha,scope=${{ matrix.images.cache_scope }},mode=max
86+
build-args: |
87+
GENESIS_TEMPLATE_VERSION=${{ github.event.inputs.genesis_template_version || '0.46.0-ant' }}
88+
GIT_SHA=${{ github.event.inputs.commit || 'main' }}
Lines changed: 25 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,24 @@
1-
name: Rebuild Workload images (triggerable)
1+
name: Rebuild Workload image
22

33
on:
44
workflow_dispatch:
55
inputs:
66
workload_commit:
7-
description: "The workload SHA commit to build"
7+
description: "The container tag"
88
required: true
99
type: string
10+
pull_request:
11+
paths:
12+
- 'workload/**'
13+
push:
14+
branches:
15+
- master
16+
paths:
17+
- 'workload/**'
18+
19+
concurrency:
20+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
21+
cancel-in-progress: true
1022

1123
permissions:
1224
contents: read
@@ -17,8 +29,6 @@ permissions:
1729
jobs:
1830
workload-container:
1931
runs-on: ubuntu-latest
20-
env:
21-
antithesis_registry_url: us-central1-docker.pkg.dev/molten-verve-216720/heliax-repository
2232
steps:
2333
- name: Checkout repo
2434
uses: actions/checkout@v4
@@ -29,7 +39,7 @@ jobs:
2939
- name: Login to GHCR
3040
uses: docker/login-action@v3
3141
with:
32-
registry: ${{ env.antithesis_registry_url }}
42+
registry: us-central1-docker.pkg.dev/molten-verve-216720/heliax-repository
3343
username: _json_key
3444
password: ${{ secrets.ANTITHESIS_GAR_JSON_KEY }}
3545
- name: Login to ghcr.io
@@ -38,10 +48,13 @@ jobs:
3848
registry: ghcr.io
3949
username: ${{ github.actor }}
4050
password: ${{ secrets.GITHUB_TOKEN }}
41-
- name: Build & Push Workload Container
42-
run: |
43-
registry_url="${{ env.antithesis_registry_url }}" sha="${{ github.event.inputs.workload_commit }}" make build-workload
44-
docker push ${{ env.antithesis_registry_url }}/workload:${{ github.event.inputs.workload_commit }}
45-
46-
docker tag ${{ env.antithesis_registry_url }}/workload:${{ github.event.inputs.workload_commit }} ghcr.io/heliaxdev/ant-workload:${{ github.event.inputs.workload_commit }}
47-
docker push ghcr.io/heliaxdev/ant-workload:${{ github.event.inputs.workload_commit }}
51+
- name: Build and push
52+
uses: docker/build-push-action@v6
53+
with:
54+
context: workload
55+
push: ${{ github.event_name != 'pull_request' }}
56+
tags: |
57+
ghcr.io/heliaxdev/ant-workload:${{ github.event.inputs.tag || github.sha }}
58+
us-central1-docker.pkg.dev/molten-verve-216720/heliax-repository/workload:${{ github.event.inputs.tag || github.sha }}
59+
cache-from: type=gha,scope=workload-image
60+
cache-to: type=gha,scope=workload-image,mode=max

0 commit comments

Comments
 (0)