@@ -5,8 +5,8 @@ description: |
55 The artifacts for all supported environments must have been downloaded
66 in "package-{EnvName}-x64" subfolders before calling this action.
77inputs :
8- version-name :
9- description : Name of the version to package
8+ tag :
9+ description : The tag to use for the distribution
1010 required : true
1111 download-url-base :
1212 description : Base url where the released distribution will be downloadable
@@ -20,13 +20,26 @@ inputs:
2020runs :
2121 using : " composite"
2222 steps :
23+ - name : Get short SHA
24+ id : slug
25+ run : echo "sha8=$(echo ${{ github.sha }} | cut -c1-7)" >> $GITHUB_OUTPUT
26+
27+ - name : Compute version name
28+ id : compute-version-name
29+ run : |
30+ if [[ "${{ inputs.tag }}" == "unstable" ]]; then
31+ echo "version-name=unstable-${{ steps.slug.outputs.sha8 }}" >> $GITHUB_OUTPUT
32+ else
33+ echo "version-name=${{ inputs.tag }}" >> $GITHUB_OUTPUT
34+ fi
35+
2336 - name : Package distribution (Linux-X64)
2437 shell : bash
2538 run : |
2639 python3 ./.github/workflows/scripts/package-distribution.py \
2740 --input package-Linux-X64/ \
2841 --dest package/ \
29- --version "${{ inputs .version-name }}" \
42+ --version "${{ steps.compute-version-name.outputs .version-name }}" \
3043 --target "linux-x64"
3144
3245 - name : Package distribution (Linux-ARM64)
3548 python3 ./.github/workflows/scripts/package-distribution.py \
3649 --input package-Linux-ARM64/ \
3750 --dest package/ \
38- --version "${{ inputs .version-name }}" \
51+ --version "${{ steps.compute-version-name.outputs .version-name }}" \
3952 --target "linux-arm64"
4053
4154 - name : Package distribution (macOS-ARM64)
4457 python3 ./.github/workflows/scripts/package-distribution.py \
4558 --input package-macOS-ARM64/ \
4659 --dest package/ \
47- --version "${{ inputs .version-name }}" \
60+ --version "${{ steps.compute-version-name.outputs .version-name }}" \
4861 --target "macos-arm64"
4962
5063 - name : Package distribution (Windows-X64)
5366 python3 ./.github/workflows/scripts/package-distribution.py \
5467 --input package-Windows-X64/ \
5568 --dest package/ \
56- --version "${{ inputs .version-name }}" \
69+ --version "${{ steps.compute-version-name.outputs .version-name }}" \
5770 --target "windows-x64"
5871
5972 - name : Package Explorer
6376 --input package-explorer/ \
6477 --dest package/ \
6578 --name "mithril-explorer" \
66- --version "${{ inputs .version-name }}"
79+ --version "${{ steps.compute-version-name.outputs .version-name }}"
6780
6881 - name : Prepare crates versions table
6982 shell : bash
@@ -165,6 +178,23 @@ runs:
165178 DOWNLOAD_URL_BASE : ${{ inputs.download-url-base }}
166179 run : ./.github/workflows/scripts/verify-distribution.sh
167180
181+ - name : Download a Docker image
182+ shell : bash
183+ run : |
184+ MITHRIL_IMAGE_ID="${{ steps.compute-version-name.outputs.version-name }}"
185+
186+ cat >> ./release-notes-addon.txt << EOF
187+
188+ ## Download a Docker image
189+ You can directly pull prebuilt Mithril Docker images:
190+
191+ | Binary | Image name | URL |
192+ | ------------------ | :----------------------------------: | :----------------------------------------------------------: |
193+ | mithril-aggregator | mithril-aggregator:$MITHRIL_IMAGE_ID | ghcr.io/input-output-hk/mithril-aggregator:$MITHRIL_IMAGE_ID |
194+ | mithril-signer | mithril-signer:$MITHRIL_IMAGE_ID | ghcr.io/input-output-hk/mithril-signer:$MITHRIL_IMAGE_ID |
195+ | mithril-client | mithril-client:$MITHRIL_IMAGE_ID | ghcr.io/input-output-hk/mithril-client:$MITHRIL_IMAGE_ID |
196+ EOF
197+
168198 - name : List packaged assets
169199 shell : bash
170200 run : ls -al ./package
0 commit comments