Skip to content

Commit 4e49a09

Browse files
authored
Merge pull request #25 from Ratio1/develop
fix: generate github releases for mainnet build
2 parents b40426f + 411e528 commit 4e49a09

File tree

1 file changed

+20
-7
lines changed

1 file changed

+20
-7
lines changed

.github/workflows/build_testnet_mainnet.yml

Lines changed: 20 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: Build and Push Testnet and Mainnet Images
22

33
on:
44
push:
5-
branches: [ main ]
5+
branches: [main]
66
# also allow manual runs
77
workflow_dispatch:
88

@@ -23,17 +23,17 @@ jobs:
2323
id: version
2424
uses: PaulHatch/semantic-version@v5.4.0
2525
with:
26-
tag_prefix: 'v'
27-
major_pattern: '(MAJOR)'
28-
minor_pattern: '(feat|feature)'
29-
version_format: '${major}.${minor}.${patch}'
26+
tag_prefix: "v"
27+
major_pattern: "(MAJOR)"
28+
minor_pattern: "(feat|feature)"
29+
version_format: "${major}.${minor}.${patch}"
3030

3131
build:
3232
runs-on: ubuntu-latest
3333
needs: [generate-version]
3434

3535
permissions:
36-
contents: read
36+
contents: write
3737
packages: write
3838

3939
steps:
@@ -64,6 +64,7 @@ jobs:
6464
ratio1/explorer:testnet
6565
6666
- name: Build & Push Mainnet Image
67+
id: build_mainnet_image
6768
uses: docker/build-push-action@v5
6869
with:
6970
context: .
@@ -77,4 +78,16 @@ jobs:
7778
tags: |
7879
ratio1/explorer:mainnet
7980
80-
81+
- name: Create GitHub Release
82+
uses: softprops/action-gh-release@v2
83+
with:
84+
tag_name: ${{ needs.generate-version.outputs.version_tag }}
85+
name: v${{ needs.generate-version.outputs.version }}
86+
body: |
87+
Docker image details:
88+
- tag: ratio1/dapp:mainnet
89+
- digest: ${{ steps.build_mainnet_image.outputs.digest }}
90+
draft: false
91+
prerelease: false
92+
env:
93+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 commit comments

Comments
 (0)