Skip to content

Add GHA workflow to build and test RPMs #26

Add GHA workflow to build and test RPMs

Add GHA workflow to build and test RPMs #26

name: RPM Build and Test
env:
# TODO: we really need to define a list of supported versions (ideally it's no more than 2)
# build is done on the lowest version and test on the highest with a "sanity test"
# stage done on all versions in the list ecept the highest
EL8_BUILD_VERSION: 8.6
EL8_VERSION: 8.8
EL9_BUILD_VERSION: 9
EL9_VERSION: 9
LEAP15_VERSION: 15.5
# Which distros to build for
DISTROS: el8 el9 leap15
# DO NOT LAND -- just to speed up testing
# TEST_TAG: pr
TEST_TAG: always_passes,vm
PACKAGING_DIR: .
NAME: argobots
on:
workflow_dispatch:
inputs:
pr-repos:
description: 'Any PR-repos that you want included in this build'
required: false
commit-message:
description: 'Commit message to use rather than the one from git'
required: false
rpm-test-version:
description: 'RPM version to test'
required: false
pull_request:
concurrency:
group: rpm-build-and-test-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
defaults:
run:
shell: bash --noprofile --norc -ueo pipefail {0}
permissions: {}
jobs:
call-rpm-buil:
uses: ./.github/workflows/rpm-build.yml

Check failure on line 46 in .github/workflows/rpm-build-and-test.yml

View workflow run for this annotation

GitHub Actions / RPM Build and Test

Invalid workflow file

The workflow is not valid. .github/workflows/rpm-build-and-test.yml (Line: 46, Col: 11): Input config-path is required, but not provided while calling. .github/workflows/rpm-build-and-test.yml (Line: 46, Col: 11): Secret token is required, but not provided while calling.
Test-with-DAOS:
# TODO: investigate how cancelling this can cancel the downstream job
name: Test RPMs with DAOS
runs-on: [self-hosted, mockbuilder]
timeout-minutes: 7200
strategy:
fail-fast: false
matrix:
# no GHA support on this branch: branch: [master, release/2.4]
# DO NOT LAND - using PR as master for now
# branch: [master]
branch: [bmurrell/run-on-dispatch]
steps:
- name: Test RPMs with DAOS
uses: convictional/[email protected]
with:
owner: daos-stack
repo: daos
github_token: ${{ secrets.GHA_WORKFLOW_TRIGGER }}
comment_downstream_url: ${{ github.event.pull_request.comments_url }}
workflow_file_name: 'rpm-build-and-test.yml'
# TODO: or rather I suspect it's a TODO, but I suspect we need to create
# a temporary branch here so as not to pollute the landing branch
# runs with these tests
ref: ${{ matrix.branch }}
wait_interval: 10
# TODO: rpm-test-version of course needs to either be the latest
# version, or better yet, no version and it installs the latest
# version
client_payload: '{"pr-repos":
"${{ env.NAME }}@PR-${{ github.event.pull_request.number }}",
"commit-message":
"Override commit pragmas",
"test-tag":
"load_mpi,vm test_core_files,vm ${{ env.TEST_TAG }}",
"rpm-test-version":
"2.5.101",
"functional-test-distros":
"${{ env.DISTROS }}"
}'
propagate_failure: true
# TODO: investigate how cancelling this can cancel the downstream job
- name: Cleanup downstream jobs
if: cancelled()
run: echo "Cancelling downstream jobs (but how?)"