Skip to content

Commit 24e9de8

Browse files
committed
fix docker
1 parent 98124bb commit 24e9de8

2 files changed

Lines changed: 10 additions & 5 deletions

File tree

.github/workflows/ci_release.yml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,11 @@ jobs:
3030
uses: ./.github/workflows/test.yml
3131
secrets: inherit
3232
with:
33-
# tag with the pr in the format of pr-1234 or the tag / branch if it is not a PR.
34-
image-tag: ${{ github.event.pull_request.number && format('pr-{0}', github.event.pull_request.number) || github.ref_name }}
33+
# Map tags to PR number, main branch, or release tag; skip pushes otherwise.
34+
image-tag: ${{ github.event_name == 'pull_request' && format('pr-{0}', github.event.pull_request.number)
35+
|| (github.ref == 'refs/heads/main' && 'main')
36+
|| (startsWith(github.ref, 'refs/tags/v') && github.ref_name)
37+
|| 'skip' }}
3538

3639
proto:
3740
uses: ./.github/workflows/proto.yml

.github/workflows/test.yml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ jobs:
1212
build-ev-node-image:
1313
name: Build ev-node Docker Image
1414
# skip building images for merge groups as they are already built on PRs and main
15-
if: github.event_name != 'merge_group'
15+
if: github.event_name != 'merge_group' && inputs.image-tag != 'skip'
1616
runs-on: ubuntu-latest
1717
permissions:
1818
packages: write
@@ -41,7 +41,7 @@ jobs:
4141
build-ev-node-evm-single-image:
4242
name: Build ev-node EVM Single Docker Image
4343
# skip building images for merge groups as they are already built on PRs and main
44-
if: github.event_name != 'merge_group'
44+
if: github.event_name != 'merge_group' && inputs.image-tag != 'skip'
4545
runs-on: ubuntu-latest
4646
permissions:
4747
packages: write
@@ -71,7 +71,7 @@ jobs:
7171
build-local-da-image:
7272
name: Build local-da Docker Image
7373
# skip building images for merge groups as they are already built on PRs and main
74-
if: github.event_name != 'merge_group'
74+
if: github.event_name != 'merge_group' && inputs.image-tag != 'skip'
7575
runs-on: ubuntu-latest
7676
permissions:
7777
packages: write
@@ -100,6 +100,7 @@ jobs:
100100

101101
docker-tests:
102102
name: Docker E2E Tests
103+
if: inputs.image-tag != 'skip'
103104
needs: build-ev-node-image
104105
runs-on: ubuntu-latest
105106
steps:
@@ -116,6 +117,7 @@ jobs:
116117

117118
docker-upgrade-tests:
118119
name: Docker Upgrade E2E Tests
120+
if: inputs.image-tag != 'skip'
119121
needs: build-ev-node-evm-single-image
120122
runs-on: ubuntu-latest
121123
steps:

0 commit comments

Comments
 (0)