Skip to content

Commit d36961b

Browse files
EgorPopelyaevgithub-actions[bot]
authored andcommitted
BACKPORT-CONFLICT
1 parent 3366310 commit d36961b

File tree

3 files changed

+93
-0
lines changed

3 files changed

+93
-0
lines changed

.github/workflows/release-10_branchoff-stable.yml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -111,3 +111,25 @@ jobs:
111111
gh auth setup-git
112112
113113
git push origin "$STABLE_BRANCH_NAME"
114+
<<<<<<< HEAD
115+
=======
116+
117+
- name: Tag RC after branch off
118+
if: ${{ inputs.tag_rc }}
119+
env:
120+
GH_TOKEN: ${{ steps.generate_write_token.outputs.token }} # or use a PAT with workflow scope
121+
run: |
122+
stable_tag_base=polkadot-${{ needs.validate-inputs.outputs.stable_version }}
123+
gh workflow run release-11_rc-automation.yml \
124+
--repo ${{ github.repository }} \
125+
--ref ${{ needs.validate-inputs.outputs.stable_version }} \
126+
--field version=${stable_tag_base}
127+
128+
tag-rc-without-branchoff:
129+
if: ${{ !inputs.is_new_stable && inputs.tag_rc }}
130+
needs: [ validate-inputs ]
131+
uses: ./.github/workflows/release-11_rc-automation.yml
132+
with:
133+
version: polkadot-${{ needs.validate-inputs.outputs.stable_version }}
134+
secrets: inherit
135+
>>>>>>> 80ab459c ([Release|CI/CD] Add flow to create a release tag in format polkadot-vX.XX.X (#10351))

.github/workflows/release-11_rc-automation.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,14 @@ on:
1313
inputs:
1414
version:
1515
description: Current release/rc version in format polkadot-stableYYMM
16+
<<<<<<< HEAD
17+
=======
18+
workflow_call:
19+
inputs:
20+
version:
21+
description: Current release/rc version in format polkadot-stableYYMM
22+
type: string
23+
>>>>>>> 80ab459c ([Release|CI/CD] Add flow to create a release tag in format polkadot-vX.XX.X (#10351))
1624

1725
jobs:
1826
tag_rc:
Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
name: Release - Create polkadot-vX.YY.Z tag
2+
# This workflow creates a final release tag in the old format (e.g. polkadot-v1.20.0) for a published release.
3+
4+
on:
5+
release:
6+
types: published
7+
8+
jobs:
9+
create-old-release-tag:
10+
runs-on: parity-default
11+
environment: release
12+
env:
13+
PGP_KMS_KEY: ${{ secrets.PGP_KMS_SIGN_COMMITS_KEY }}
14+
PGP_KMS_HASH: ${{ secrets.PGP_KMS_HASH }}
15+
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
16+
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
17+
AWS_DEFAULT_REGION: ${{ secrets.AWS_DEFAULT_REGION }}
18+
19+
steps:
20+
- name: Install pgpkkms
21+
run: |
22+
# Install pgpkms that is used to sign commits
23+
pip install git+https://github.com/paritytech-release/pgpkms.git@6cb1cecce1268412189b77e4b130f4fa248c4151
24+
25+
- name: Generate content write token for the release automation
26+
id: generate_write_token
27+
uses: actions/create-github-app-token@67018539274d69449ef7c02e8e71183d1719ab42 # v2.1.4
28+
with:
29+
app-id: ${{ vars.RELEASE_AUTOMATION_APP_ID }}
30+
private-key: ${{ secrets.RELEASE_AUTOMATION_APP_PRIVATE_KEY }}
31+
owner: paritytech
32+
33+
- name: Checkout
34+
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
35+
with:
36+
ref: ${{ github.event.release.tag_name }}
37+
token: ${{ steps.generate_write_token.outputs.token }}
38+
39+
- name: Import gpg keys
40+
run: |
41+
. ./.github/scripts/common/lib.sh
42+
43+
import_gpg_keys
44+
45+
- name: Config git
46+
run: |
47+
git config --global commit.gpgsign true
48+
git config --global gpg.program /home/runner/.local/bin/pgpkms-git
49+
git config --global user.name "ParityReleases"
50+
git config --global user.email "release-team@parity.io"
51+
git config --global user.signingKey "D8018FBB3F534D866A45998293C5FB5F6A367B51"
52+
53+
- name: Create old release tag
54+
env:
55+
GH_TOKEN: ${{ steps.generate_write_token.outputs.token }}
56+
run: |
57+
. ./.github/scripts/common/lib.sh
58+
59+
version=$(get_polkadot_node_version_from_code)
60+
echo "Extracted node version: $version"
61+
62+
git tag -s "polkadot-v${version}" -m "Old release tag polkadot-v${version}"
63+
git push origin "polkadot-v${version}"

0 commit comments

Comments
 (0)