Skip to content

Commit

Permalink
Fix runtime-publishing job & update upload action to v4 (#851)
Browse files Browse the repository at this point in the history
Co-authored-by: Mario Sánchez García <mario@opslayer.com>
  • Loading branch information
girazoki and mario-sangar authored Feb 6, 2025
1 parent e513d56 commit 5a3d93b
Show file tree
Hide file tree
Showing 8 changed files with 40 additions and 246 deletions.
7 changes: 4 additions & 3 deletions .github/workflows/docker-runtime-draft.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,9 @@ jobs:
cp target/production/container-chain-frontier-node binaries/container-chain-frontier-node-${{matrix.cpu}}
cp target/production/container-chain-simple-node binaries/container-chain-simple-node-${{matrix.cpu}}
- name: Upload binaries
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: binaries
name: binaries-${{ matrix.chain.cpu }}
path: binaries
docker-tanssi:
runs-on: ubuntu-latest
Expand All @@ -67,7 +67,8 @@ jobs:
uses: actions/checkout@v4
- uses: actions/download-artifact@v4
with:
name: binaries
pattern: binaries-${{ matrix.chain.cpu }}
merge-multiple: true
path: build
- name: Prepare
id: prep
Expand Down
7 changes: 4 additions & 3 deletions .github/workflows/prepare-binary.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,9 @@ jobs:
cp target/production/container-chain-frontier-node binaries/container-chain-frontier-node-${{matrix.cpu}}
cp target/production/container-chain-simple-node binaries/container-chain-simple-node-${{matrix.cpu}}
- name: Upload binary
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: binaries
name: binaries-${{matrix.cpu}}
path: binaries

####### Prepare the release draft #######
Expand All @@ -61,7 +61,8 @@ jobs:
ref: ${{ github.event.inputs.sha }}
- uses: actions/download-artifact@v4
with:
name: binaries
pattern: binaries-*
merge-multiple: true
path: build
- name: Prepare
id: prep
Expand Down
7 changes: 4 additions & 3 deletions .github/workflows/prepare-tanssi-relay-binary.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,9 @@ jobs:
cp target/production/tanssi-relay-execute-worker binaries/tanssi-relay-execute-worker-${{matrix.cpu}}
cp target/production/tanssi-relay-prepare-worker binaries/tanssi-relay-prepare-worker-${{matrix.cpu}}
- name: Upload binary
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: binaries
name: binaries-${{matrix.cpu}}
path: binaries

####### Prepare the release draft #######
Expand All @@ -61,7 +61,8 @@ jobs:
ref: ${{ github.event.inputs.sha }}
- uses: actions/download-artifact@v4
with:
name: binaries
pattern: binaries-*
merge-multiple: true
path: build
- name: Prepare
id: prep
Expand Down
7 changes: 4 additions & 3 deletions .github/workflows/publish-binary-tannsi-relay.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,9 +55,9 @@ jobs:
cp target/production/tanssi-relay-execute-worker binaries/tanssi-relay-execute-worker-${{matrix.cpu}}
cp target/production/tanssi-relay-prepare-worker binaries/tanssi-relay-prepare-worker-${{matrix.cpu}}
- name: Upload binaries
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: binaries
name: binaries-${{matrix.cpu}}
path: binaries

####### Prepare the release draft #######
Expand Down Expand Up @@ -113,7 +113,8 @@ jobs:
steps:
- uses: actions/download-artifact@v4
with:
name: binaries
pattern: binaries-*
merge-multiple: true
path: build
- name: Upload dancelight
uses: actions/upload-release-asset@v1
Expand Down
213 changes: 0 additions & 213 deletions .github/workflows/publish-runtime-chevdor.yml

This file was deleted.

23 changes: 12 additions & 11 deletions .github/workflows/publish-runtime.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,8 @@ jobs:
####### Build runtimes with srtool #######

setup-scripts:
runs-on: self-hosted
runs-on: ubuntu-latest
steps:
## Use scripts and tools from current branch
- uses: actions/checkout@v4
- name: Upload scripts
uses: actions/upload-artifact@v4
Expand Down Expand Up @@ -85,14 +84,14 @@ jobs:
matrix:
chain: ${{ fromJson(needs.matrix_prep.outputs.matrix_tests) }}
srtool_image:
- moondancelabs/srtool
- paritytech/srtool
srtool_image_tag:
- 1.75.0
- 1.81.0
# Change this once https://github.com/paritytech/srtool/pull/81 gets merged
srtool_build_base_dockerhub:
- moondancelabs/srtool
srtool_build_source_image_tag:
- temp-1.75
- temp-1.81

steps:
- uses: actions/checkout@v4
Expand Down Expand Up @@ -134,6 +133,7 @@ jobs:
GH_WORKFLOW_MATRIX_SRTOOL_IMAGE: ${{ matrix.srtool_image }}
GH_WORKFLOW_MATRIX_SRTOOL_IMAGE_TAG: ${{ matrix.srtool_image_tag }}
run: |
chmod u+x ./original-scripts/build-runtime-srtool.sh
./original-scripts/build-runtime-srtool.sh
- name: Summary
Expand All @@ -142,14 +142,13 @@ jobs:
cat ${{ matrix.chain.runtime_name }}-srtool-digest.json
cp ${{ steps.srtool_build.outputs.wasm_compressed }} ${{ matrix.chain.runtime_name }}-runtime.compact.compressed.wasm
- name: Archive Artifacts for ${{ matrix.chain }}
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: runtime-info
name: runtime-info-${{ matrix.chain.runtime_name }}
path: |
${{ matrix.chain.runtime_name }}-runtime.compact.compressed.wasm
${{ matrix.chain.runtime_name }}-srtool-digest.json
####### Prepare the release draft #######
prepare-draft-release:
runs-on: ubuntu-latest
Expand All @@ -175,7 +174,8 @@ jobs:
- name: Download runtime-info
uses: actions/download-artifact@v4
with:
name: runtime-info
pattern: runtime-info-*
merge-multiple: true
path: build
- name: Generate release body
env:
Expand Down Expand Up @@ -214,8 +214,9 @@ jobs:
- name: Download ${{ matrix.chain }} runtime
uses: actions/download-artifact@v4
with:
name: runtime-info
path: build
pattern: runtime-info-*
merge-multiple: true
path: build
- name: Get runtime version
id: get-runtime-ver
run: |
Expand Down
Loading

0 comments on commit 5a3d93b

Please sign in to comment.