1818 - ' portal/**'
1919 - ' **/*.md'
2020 - ' .github/workflows/portal*.yml'
21- - ' nimbus_verified_proxy/**'
22- - ' .github/workflows/nimbus_verified_proxy.yml'
2321
2422 workflow_dispatch :
2523
2624env :
27- REGISTRY_IMAGE : statusim/nimbus-eth1
25+ EL_REGISTRY_IMAGE : statusim/nimbus-eth1
26+ PROXY_REGISTRY_IMAGE : statusim/nvp
2827
2928jobs :
3029 build :
@@ -52,11 +51,11 @@ jobs:
5251 # Replace '/' with '-' to create a unique identifier for this platform
5352 echo "PLATFORM_PAIR=${platform//\//-}" >> $GITHUB_ENV
5453
55- - name : Docker meta
54+ - name : Docker meta (EL)
5655 id : meta
5756 uses : docker/metadata-action@v5
5857 with :
59- images : ${{ env.REGISTRY_IMAGE }}
58+ images : ${{ env.EL_REGISTRY_IMAGE }}
6059
6160 - name : Checkout Repository
6261 uses : actions/checkout@v4
7776 context : .
7877 platforms : ${{ matrix.platform }}
7978 labels : ${{ steps.meta.outputs.labels }}
80- tags : ${{ env.REGISTRY_IMAGE }}
79+ tags : ${{ env.EL_REGISTRY_IMAGE }}
8180 outputs : type=image,push-by-digest=true,name-canonical=true,push=true
8281
8382 - name : Export digest
@@ -94,18 +93,56 @@ jobs:
9493 if-no-files-found : error
9594 retention-days : 1
9695
96+ - name : Docker meta (proxy)
97+ id : meta-proxy
98+ uses : docker/metadata-action@v5
99+ with :
100+ images : ${{ env.PROXY_REGISTRY_IMAGE }}
101+
102+ - name : Build and push proxy by digest
103+ id : build-proxy
104+ uses : docker/build-push-action@v6
105+ with :
106+ context : .
107+ file : Dockerfile.proxy
108+ platforms : ${{ matrix.platform }}
109+ labels : ${{ steps.meta-proxy.outputs.labels }}
110+ tags : ${{ env.PROXY_REGISTRY_IMAGE }}
111+ outputs : type=image,push-by-digest=true,name-canonical=true,push=true
112+
113+ - name : Export proxy digest
114+ run : |
115+ mkdir -p ${{ runner.temp }}/proxy-digests
116+ digest="${{ steps.build-proxy.outputs.digest }}"
117+ touch "${{ runner.temp }}/proxy-digests/${digest#sha256:}"
118+
119+ - name : Upload proxy digest
120+ uses : actions/upload-artifact@v4
121+ with :
122+ name : proxy-digests-${{ env.PLATFORM_PAIR }}
123+ path : ${{ runner.temp }}/proxy-digests/*
124+ if-no-files-found : error
125+ retention-days : 1
126+
97127 merge :
98128 runs-on : ubuntu-latest
99129 needs :
100130 - build
101131 steps :
102- - name : Download digests
132+ - name : Download el digests
103133 uses : actions/download-artifact@v4
104134 with :
105135 path : ${{ runner.temp }}/digests
106136 pattern : digests-*
107137 merge-multiple : true
108138
139+ - name : Download proxy digests
140+ uses : actions/download-artifact@v4
141+ with :
142+ path : ${{ runner.temp }}/proxy-digests
143+ pattern : proxy-digests-*
144+ merge-multiple : true
145+
109146 - name : Login to Docker Hub
110147 uses : docker/login-action@v3
111148 with :
@@ -119,7 +156,16 @@ jobs:
119156 id : meta
120157 uses : docker/metadata-action@v5
121158 with :
122- images : ${{ env.REGISTRY_IMAGE }}
159+ images : ${{ env.EL_REGISTRY_IMAGE }}
160+ tags : |
161+ type=ref,event=branch
162+ type=sha,prefix={{branch}}-
163+
164+ - name : Docker meta (proxy)
165+ id : meta-proxy
166+ uses : docker/metadata-action@v5
167+ with :
168+ images : ${{ env.PROXY_REGISTRY_IMAGE }}
123169 tags : |
124170 type=ref,event=branch
125171 type=sha,prefix={{branch}}-
@@ -129,8 +175,21 @@ jobs:
129175 run : |
130176 jq -cr '.tags | map("-t " + .) | join(" ")' <<< "$DOCKER_METADATA_OUTPUT_JSON"
131177 docker buildx imagetools create $(jq -cr '.tags | map("-t " + .) | join(" ")' <<< "$DOCKER_METADATA_OUTPUT_JSON") \
132- $(printf '${{ env.REGISTRY_IMAGE }}@sha256:%s ' *)
178+ $(printf '${{ env.EL_REGISTRY_IMAGE }}@sha256:%s ' *)
179+
180+ - name : Create proxy manifest list and push
181+ working-directory : ${{ runner.temp }}/proxy-digests
182+ env :
183+ DOCKER_METADATA_OUTPUT_JSON : ${{ steps.meta-proxy.outputs.json }}
184+ run : |
185+ jq -cr '.tags | map("-t " + .) | join(" ")' <<< "$DOCKER_METADATA_OUTPUT_JSON"
186+ docker buildx imagetools create $(jq -cr '.tags | map("-t " + .) | join(" ")' <<< "$DOCKER_METADATA_OUTPUT_JSON") \
187+ $(printf '${{ env.PROXY_REGISTRY_IMAGE }}@sha256:%s ' *)
133188
134189 - name : Inspect image
135190 run : |
136- docker buildx imagetools inspect ${{ env.REGISTRY_IMAGE }}:${{ steps.meta.outputs.version }}
191+ docker buildx imagetools inspect ${{ env.EL_REGISTRY_IMAGE }}:${{ steps.meta.outputs.version }}
192+
193+ - name : Inspect proxy image
194+ run : |
195+ docker buildx imagetools inspect ${{ env.PROXY_REGISTRY_IMAGE }}:${{ steps.meta.outputs.version }}
0 commit comments