Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tmt: automatically determine copr version matrix #245

Merged
merged 1 commit into from
Feb 5, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 14 additions & 1 deletion .github/workflows/tmt.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,25 @@ permissions:
actions: write

jobs:
get-os-versions-job:
runs-on: ubuntu-latest
outputs:
os-versions: ${{ steps.get-os-versions-step.outputs.os_versions }}
steps:
- id: get-os-versions-step
run: |
sudo apt-get install jq curl
os_versions=`curl -sL https://copr.fedorainfracloud.org/api_3/mock-chroots/list | jq -rc '[. | keys[] | select(.|match("fedora-[0-9]+|rawhide")) | sub("^fedora-"; "") | sub("-.*$";"")] | unique'`
# Get OS versions comma separated with properly quoted rawhide
>&2 echo "$os_versions"
echo "os_versions=$os_versions" >> $GITHUB_OUTPUT
run-tmt:
needs: get-os-versions-job
strategy:
fail-fast: false
matrix:
os: [fedora]
version: [38, 39, rawhide]
version: ${{ fromJSON(needs.get-os-versions-job.outputs.os-versions) }}
strategy: [standalone, big-merge, bootstrap]
include:
- strategy: standalone
Expand Down