@@ -5,8 +5,8 @@ description: |
5
5
The artifacts for all supported environments must have been downloaded
6
6
in "package-{EnvName}-x64" subfolders before calling this action.
7
7
inputs :
8
- version-name :
9
- description : Name of the version to package
8
+ tag :
9
+ description : The tag to use for the distribution
10
10
required : true
11
11
download-url-base :
12
12
description : Base url where the released distribution will be downloadable
@@ -20,13 +20,28 @@ inputs:
20
20
runs :
21
21
using : " composite"
22
22
steps :
23
+ - name : Get short SHA
24
+ id : slug
25
+ shell : bash
26
+ run : echo "sha8=$(echo ${{ github.sha }} | cut -c1-7)" >> $GITHUB_OUTPUT
27
+
28
+ - name : Compute version name
29
+ id : compute-version-name
30
+ shell : bash
31
+ run : |
32
+ if [[ "${{ inputs.tag }}" == "unstable" ]]; then
33
+ echo "version-name=unstable-${{ steps.slug.outputs.sha8 }}" >> $GITHUB_OUTPUT
34
+ else
35
+ echo "version-name=${{ inputs.tag }}" >> $GITHUB_OUTPUT
36
+ fi
37
+
23
38
- name : Package distribution (Linux-X64)
24
39
shell : bash
25
40
run : |
26
41
python3 ./.github/workflows/scripts/package-distribution.py \
27
42
--input package-Linux-X64/ \
28
43
--dest package/ \
29
- --version "${{ inputs .version-name }}" \
44
+ --version "${{ steps.compute-version-name.outputs .version-name }}" \
30
45
--target "linux-x64"
31
46
32
47
- name : Package distribution (Linux-ARM64)
35
50
python3 ./.github/workflows/scripts/package-distribution.py \
36
51
--input package-Linux-ARM64/ \
37
52
--dest package/ \
38
- --version "${{ inputs .version-name }}" \
53
+ --version "${{ steps.compute-version-name.outputs .version-name }}" \
39
54
--target "linux-arm64"
40
55
41
56
- name : Package distribution (macOS-ARM64)
44
59
python3 ./.github/workflows/scripts/package-distribution.py \
45
60
--input package-macOS-ARM64/ \
46
61
--dest package/ \
47
- --version "${{ inputs .version-name }}" \
62
+ --version "${{ steps.compute-version-name.outputs .version-name }}" \
48
63
--target "macos-arm64"
49
64
50
65
- name : Package distribution (Windows-X64)
53
68
python3 ./.github/workflows/scripts/package-distribution.py \
54
69
--input package-Windows-X64/ \
55
70
--dest package/ \
56
- --version "${{ inputs .version-name }}" \
71
+ --version "${{ steps.compute-version-name.outputs .version-name }}" \
57
72
--target "windows-x64"
58
73
59
74
- name : Package Explorer
63
78
--input package-explorer/ \
64
79
--dest package/ \
65
80
--name "mithril-explorer" \
66
- --version "${{ inputs .version-name }}"
81
+ --version "${{ steps.compute-version-name.outputs .version-name }}"
67
82
68
83
- name : Prepare crates versions table
69
84
shell : bash
@@ -127,6 +142,27 @@ runs:
127
142
\`git tag -d unstable && git fetch origin tag unstable\`
128
143
EOF
129
144
145
+ - name : Download a binary asset
146
+ shell : bash
147
+ run : |
148
+ cat >> ./release-notes-addon.txt << EOF
149
+
150
+ ## Download a binary asset
151
+ To simplify the installation and updating of Mithril binaries, we have created a one line installer that downloads and installs the Mithril binaries for you.
152
+ This installer is available for Linux and macOS and supports the Mithril signer, Mithril aggregator, and Mithril client CLI.
153
+
154
+ Use the following commands to install the Mithril nodes:
155
+
156
+ - Download the **Mithril signer** in the current directory:
157
+ \`curl --proto '=https' --tlsv1.2 -sSf https://raw.githubusercontent.com/input-output-hk/mithril/refs/heads/main/mithril-install.sh | sh -s -- -c mithril-signer -d ${{ inputs.tag }} -p $(pwd)\`
158
+
159
+ - Download the **Mithril client CLI** in the current directory:
160
+ \`curl --proto '=https' --tlsv1.2 -sSf https://raw.githubusercontent.com/input-output-hk/mithril/refs/heads/main/mithril-install.sh | sh -s -- -c mithril-client -d ${{ inputs.tag }} -p $(pwd)\`
161
+
162
+ - Download the **Mithril aggregator** in the current directory:
163
+ \`curl --proto '=https' --tlsv1.2 -sSf https://raw.githubusercontent.com/input-output-hk/mithril/refs/heads/main/mithril-install.sh | sh -s -- -c mithril-aggregator -d ${{ inputs.tag }} -p $(pwd)\`
164
+ EOF
165
+
130
166
- name : Create and sign sha256 checksum
131
167
shell : bash
132
168
env :
@@ -141,6 +177,27 @@ runs:
141
177
DOWNLOAD_URL_BASE : ${{ inputs.download-url-base }}
142
178
run : ./.github/workflows/scripts/verify-distribution.sh
143
179
180
+ - name : Download a Docker image
181
+ shell : bash
182
+ run : |
183
+ if [[ "${{ inputs.tag }}" == "unstable" ]]; then
184
+ MITHRIL_IMAGE_ID="main-${{ steps.slug.outputs.sha8 }}"
185
+ else
186
+ MITHRIL_IMAGE_ID="${{ inputs.tag }}-${{ steps.slug.outputs.sha8 }}"
187
+ fi
188
+
189
+ cat >> ./release-notes-addon.txt << EOF
190
+
191
+ ## Download a Docker image
192
+ You can directly pull prebuilt Mithril Docker images:
193
+
194
+ | Binary | Image name | URL |
195
+ | ------------------ | :----------------------------------: | :----------------------------------------------------------: |
196
+ | mithril-aggregator | mithril-aggregator:$MITHRIL_IMAGE_ID | ghcr.io/input-output-hk/mithril-aggregator:$MITHRIL_IMAGE_ID |
197
+ | mithril-signer | mithril-signer:$MITHRIL_IMAGE_ID | ghcr.io/input-output-hk/mithril-signer:$MITHRIL_IMAGE_ID |
198
+ | mithril-client | mithril-client:$MITHRIL_IMAGE_ID | ghcr.io/input-output-hk/mithril-client:$MITHRIL_IMAGE_ID |
199
+ EOF
200
+
144
201
- name : List packaged assets
145
202
shell : bash
146
203
run : ls -al ./package
0 commit comments