Skip to content

Commit

Permalink
Enable yaml checks in CI
Browse files Browse the repository at this point in the history
Signed-off-by: ybonatakis <ybonatakis@suse.com>
  • Loading branch information
b10n1k committed Feb 12, 2024
1 parent 10683a4 commit 8cade01
Show file tree
Hide file tree
Showing 5 changed files with 22 additions and 1 deletion.
7 changes: 6 additions & 1 deletion .github/workflows/isotovideo-check-all-test-modules.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,9 @@ jobs:
steps:
- uses: actions/checkout@v2
- name: Run isotovideo against test code, fail if any test module failed
run: podman run --rm -it -v .:/tests:Z --entrypoint '' registry.opensuse.org/devel/openqa/containers/isotovideo:qemu-x86-jq /bin/sh -c 'isotovideo qemu_no_kvm=1 casedir=/tests && jq .result testresults/result-*.json | grep -v ok && echo "Test modules failed" && exit 1'
env:
image: registry.opensuse.org/devel/openqa/containers/isotovideo:qemu-x86-jq
isotovideo: isotovideo qemu_no_kvm=1 casedir=/tests
jq_filter: jq .result testresults/result-*.json
err_msg: Test modules failed
run: docker run --rm -it -v .:/tests:Z --entrypoint '' $image /bin/sh -c '$isotovideo && $jq_filter | grep ok || (echo "$err_msg" && exit 1)'
15 changes: 15 additions & 0 deletions .github/workflows/yaml-checks.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
---
name: yamllint
on: [push, pull_request]

jobs:
yamllint:
runs-on: ubuntu-latest
container:
image: registry.opensuse.org/devel/openqa/containers/os-autoinst_dev
steps:
- uses: actions/checkout@v4
- name: Validate yamls
run: |
git config --global --add safe.directory '*'
yamllint --strict $(git ls-files "*.yml" "*.yaml" 2> /dev/null || find . -name '*.y*ml')
Empty file added .gitignore
Empty file.
Empty file added .yamlignore
Empty file.
1 change: 1 addition & 0 deletions .yamllint

0 comments on commit 8cade01

Please sign in to comment.