tests: Add a check for valid snapshot urls

This pulls the list of snapshots from the rpmrepo API, greps the
codebase for all uses of rpmrepo.osbuild.org that look like a snapshot
name, and then checks to make sure they are still valid.

This is the same script as osbuild-composer, except that it also skips
checking ./test/data/stages/ which has rpm urls that look like snapshot
urls.
This commit is contained in:
Brian C. Lane 2023-08-10 11:48:33 -07:00 committed by Ondřej Budai
parent 694e956104
commit 68f4c5bd5f
2 changed files with 191 additions and 0 deletions

View file

@ -44,3 +44,14 @@ jobs:
with:
severity: warning
token: ${{ secrets.GITHUB_TOKEN }}
snapshots:
name: "🔍 Check for valid snapshot urls"
runs-on: ubuntu-20.04
steps:
- name: Check out code into the Go module directory
uses: actions/checkout@v3
with:
ref: ${{ github.event.pull_request.head.sha }}
- name: Check for valid snapshot urls
run: ./tools/check-snapshots --errors-only .