Skip to content

Commit a7c1552

Browse files
committed
Build and workflow updates and fixes
- Fix Plenum version format in the indy-node deb package. - Enable workflows on the `ubuntu-22.04` branch. - Set concurrency rules on PR and Push workflows. - Cancel in progress runs when stating a new one. - Ensure tests are running on latest version of Ubuntu, and with Python 3.10 (the default on Ubuntu 22.04). Signed-off-by: Wade Barnes <wade@neoterictech.ca>
1 parent c655ff1 commit a7c1552

File tree

6 files changed

+22
-7
lines changed

6 files changed

+22
-7
lines changed

.github/actions/getNewNodeVersion/action.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ runs:
1919
- name: Set up Python
2020
uses: actions/setup-python@v5
2121
with:
22-
python-version: '3.8'
22+
python-version: '3.10'
2323
- name: Get Versions
2424
id: versions
2525
shell: bash
@@ -35,4 +35,4 @@ runs:
3535
echo "nodeVersion=$nodeVersion" >> $GITHUB_OUTPUT
3636
echo "::group::DEBUG"
3737
echo "nodeVersion is set to $nodeVersion"
38-
echo "::endgroup::"
38+
echo "::endgroup::"

.github/workflows/PR.yaml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,14 @@ on:
77

88
branches:
99
- main
10+
- ubuntu-22.04
1011

1112
workflow_dispatch:
1213

14+
concurrency:
15+
group: ${{ github.workflow }}-${{ github.ref }}
16+
cancel-in-progress: true
17+
1318
jobs:
1419
workflow-setup:
1520
name: Initialize Workflow
@@ -82,4 +87,4 @@ jobs:
8287
needs: [workflow-setup, indy_node_tests]
8388
if: ${{ needs.workflow-setup.outputs.testsNeeded == 'false' || success() }}
8489
steps:
85-
- run: 'echo "Just a status Check (Always true, when executed) for branch protection rules(blocks merging while test are running and if tests fail)." '
90+
- run: 'echo "Just a status Check (Always true, when executed) for branch protection rules(blocks merging while test are running and if tests fail)." '

.github/workflows/Push.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,17 @@ on:
44
branches:
55
- main
66
- test-automation-integration
7+
- ubuntu-22.04
78
paths:
89
- '**.py'
910
- '.github/**'
1011
- 'build-scripts/**'
1112
- 'bump_version.sh'
1213

14+
concurrency:
15+
group: ${{ github.workflow }}-${{ github.ref }}
16+
cancel-in-progress: true
17+
1318
jobs:
1419
workflow-setup:
1520
name: Initialize Workflow

.github/workflows/reuseable_test.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ on:
1313
jobs:
1414
indy_node_tests:
1515
name: Sliced Module Tests
16-
runs-on: ubuntu-20.04
16+
runs-on: ubuntu-latest
1717
# Fix for scacap/action-surefire-report out of memory error:
1818
# - https://github.com/ScaCap/action-surefire-report/issues/17
1919
env:

.github/workflows/tag.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,15 +33,15 @@ jobs:
3333
bump_version:
3434
name: Bump Version Number
3535
needs: taginfos
36-
runs-on: ubuntu-20.04
36+
runs-on: ubuntu-latest
3737
steps:
3838
- name: Check out code
3939
uses: actions/checkout@v4
4040

4141
- name: Set up Python
4242
uses: actions/setup-python@v5
4343
with:
44-
python-version: '3.8'
44+
python-version: '3.10'
4545

4646
- name: Install deps for version change
4747
run: |

build-scripts/ubuntu-2204/build-indy_node.sh

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,12 @@ cd "${TMP_DIR}/build-scripts/ubuntu-2204"
1616
./prepare-package.sh "${TMP_DIR}" indy_node "${VERSION}" debian-packages
1717

1818
echo "Fetching the indy-plenum version from setup.py and converting it to deb format ..."
19-
plenumDebVersion=$(grep -oP "indy-plenum==\d+.\d+.\d+((-|.)?(rc|dev)\d+)?" ${TMP_DIR}/setup.py | grep -oP "\d+.\d+.\d+((-|.)?(rc|dev)\d+)?" | sed 's/\./\~/3')
19+
# Converts Versions defined in the following forms to their equivalent dep version format:
20+
# 1.14.0.rc0 ==> 1.14.0~rc0
21+
# 1.14.0-rc0 ==> 1.14.0~rc0
22+
# 1.14.0.dev0654678970 ==> 1.14.0~dev0654678970
23+
# 1.14.0-dev0654678970 ==> 1.14.0~dev0654678970
24+
plenumDebVersion=$(grep -oP "indy-plenum==\d+.\d+.\d+((-|.)?(rc|dev)\d+)?" ${TMP_DIR}/setup.py | grep -oP "\d+.\d+.\d+((-|.)?(rc|dev)\d+)?" | sed 's/\./\~/3' | sed 's/\-/\~/1')
2025
echo "plenumDebVersion: ${plenumDebVersion}"
2126

2227
sed -i "s/{package_name}/${PACKAGE_NAME}/" "prerm"

0 commit comments

Comments
 (0)