forked from chevdor/srtool-actions
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merged chevdor/srtool-actions 'v0.6.0'
- Loading branch information
1 parent
4d58b15
commit ea89d00
Showing
17 changed files
with
244 additions
and
110 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
|
||
== Contributing | ||
|
||
WARNING: This project is using `asciidoc` for its documentation. You should **not** edit any mardown file (`.md`) as your changes would be dismissed. | ||
|
||
Instead you should be editing the `.adoc` file and the markdown files will be generated. If you create a PR and do not have any of the required tooling, feel free to only edit the `.adoc.` files and I will generate the new `.md`. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,13 +2,11 @@ | |
|
||
<table> | ||
<colgroup> | ||
<col style="width: 33%" /> | ||
<col style="width: 33%" /> | ||
<col style="width: 33%" /> | ||
<col style="width: 50%" /> | ||
<col style="width: 50%" /> | ||
</colgroup> | ||
<tbody> | ||
<tr class="odd"> | ||
<td style="text-align: left;"><p><img src="https://github.com/chevdor/srtool-actions/actions/workflows/bridges.yml/badge.svg?branch=master" alt="badge" /></p></td> | ||
<td style="text-align: left;"><p><img src="https://github.com/chevdor/srtool-actions/actions/workflows/cumulus.yml/badge.svg?branch=master" alt="badge" /></p></td> | ||
<td style="text-align: left;"><p><img src="https://github.com/chevdor/srtool-actions/actions/workflows/polkadot.yml/badge.svg?branch=master" alt="badge" /></p></td> | ||
</tr> | ||
|
@@ -70,10 +68,10 @@ Make sure you store the yml files shown below in your repository under `.github/ | |
matrix: | ||
chain: ["statemine", "westmint"] | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/checkout@v3 | ||
- name: Srtool build | ||
id: srtool_build | ||
uses: chevdor/srtool-actions@v0.1.0 | ||
uses: chevdor/srtool-actions@v0.6.0 | ||
with: | ||
chain: ${{ matrix.chain }} | ||
runtime_dir: polkadot-parachains/${{ matrix.chain }}-runtime | ||
|
@@ -96,10 +94,10 @@ Make sure you store the yml files shown below in your repository under `.github/ | |
matrix: | ||
chain: ["westend"] | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/checkout@v3 | ||
- name: Srtool build | ||
id: srtool_build | ||
uses: chevdor/srtool-actions@v0.1.0 | ||
uses: chevdor/srtool-actions@v0.6.0 | ||
with: | ||
chain: ${{ matrix.chain }} | ||
- name: Summary | ||
|
@@ -123,10 +121,10 @@ Make sure you store the yml files shown below in your repository under `.github/ | |
matrix: | ||
chain: ["statemine", "westmint"] | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/checkout@v3 | ||
- name: Srtool build | ||
id: srtool_build | ||
uses: chevdor/srtool-actions@v0.1.0 | ||
uses: chevdor/srtool-actions@v0.6.0 | ||
with: | ||
chain: ${{ matrix.chain }} | ||
runtime_dir: polkadot-parachains/${{ matrix.chain }}-runtime | ||
|
@@ -143,8 +141,87 @@ Make sure you store the yml files shown below in your repository under `.github/ | |
${{ steps.srtool_build.outputs.wasm }} | ||
${{ matrix.chain }}-srtool-digest.json | ||
|
||
## Environmental variables and BUILD\_OPTS | ||
|
||
name: Srtool build | ||
|
||
on: push | ||
|
||
jobs: | ||
srtool: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
chain: ["statemine", "westmint"] | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Srtool build | ||
id: srtool_build | ||
uses: chevdor/[email protected] | ||
env: | ||
# optional: will be passed to docker srtool run cmd | ||
BUILD_OPTS: "--features on-chain-release-build" | ||
with: | ||
chain: ${{ matrix.chain }} | ||
runtime_dir: polkadot-parachains/${{ matrix.chain }}-runtime | ||
- name: Summary | ||
run: | | ||
echo '${{ steps.srtool_build.outputs.json }}' | jq . > ${{ matrix.chain }}-srtool-digest.json | ||
cat ${{ matrix.chain }}-srtool-digest.json | ||
echo "Runtime location: ${{ steps.srtool_build.outputs.wasm }}" | ||
|
||
## Environmental variables and parachain overrides | ||
|
||
name: Srtool build | ||
|
||
on: push | ||
|
||
jobs: | ||
srtool: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
chain: ["statemine", "westmint"] | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Srtool build | ||
id: srtool_build | ||
uses: chevdor/[email protected] | ||
env: | ||
# optional: will override the parachain pallet ID and authorize_upgrade call ID, | ||
# which will result in a different parachain_authorize_upgrade_hash | ||
# the hex values must be quoted | ||
PARACHAIN_PALLET_ID: "0x1e" | ||
AUTHORIZE_UPGRADE_PREFIX: "0x02" | ||
with: | ||
chain: ${{ matrix.chain }} | ||
runtime_dir: polkadot-parachains/${{ matrix.chain }}-runtime | ||
- name: Summary | ||
run: | | ||
echo '${{ steps.srtool_build.outputs.json }}' | jq . > ${{ matrix.chain }}-srtool-digest.json | ||
cat ${{ matrix.chain }}-srtool-digest.json | ||
echo "Runtime location: ${{ steps.srtool_build.outputs.wasm }}" | ||
|
||
## Parachain overrides | ||
|
||
Similar to [subwasm](https://github.com/chevdor/subwasm), the parachain pallet ID and the `authorize_upgrade` call ID can be overriden by `PARACHAIN_PALLET_ID` and `AUTHORIZE_UPGRADE_PREFIX` environmental variables, respectively. It will affect the generated proposal hash `parachain_authorize_upgrade_hash`. | ||
|
||
If unset, the two envs will have the following default values: | ||
|
||
- `PARACHAIN_PALLET_ID`: `0x01` | ||
|
||
- `AUTHORIZE_UPGRADE_PREFIX`: `0x03` | ||
|
||
## Contributing | ||
|
||
This project is using `asciidoc` for its documentation. You should **not** edit any mardown file (`.md`) as your changes would be dismissed. | ||
|
||
Instead you should be editing the `.adoc` file and the markdown files will be generated. If you create a PR and do not have any of the required tooling, feel free to only edit the `.adoc.` files and I will generate the new `.md`. | ||
|
||
## Dev notes | ||
|
||
### Tooling: `act` | ||
|
||
Due to a [bug in act](https://github.com/nektos/act/issues/655), the defaults defined in the action are not applied. That means **must** pass all the inputs while testing with `act`. | ||
|
||
You can test locally using [act](https://github.com/nektos/act): | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.