CI updates
This commit is contained in:
@@ -10,14 +10,24 @@ env:
|
|||||||
jobs:
|
jobs:
|
||||||
job-yaml-check:
|
job-yaml-check:
|
||||||
if: true
|
if: true
|
||||||
strategy: { matrix: { container: ['alpine:3.18','alpine:edge'] } }
|
strategy:
|
||||||
|
fail-fast: false
|
||||||
|
matrix:
|
||||||
|
include:
|
||||||
|
- container: 'alpine:3.16'
|
||||||
|
- container: 'alpine:3.17'
|
||||||
|
- container: 'alpine:3.18'
|
||||||
|
- container: 'alpine:edge'
|
||||||
name: ${{ format('{0}', matrix.container) }}
|
name: ${{ format('{0}', matrix.container) }}
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
container: ${{ matrix.container }}
|
container: ${{ matrix.container }}
|
||||||
steps:
|
steps:
|
||||||
- name: ${{ format('Install packages {0}', matrix.container) }}
|
- name: ${{ format('Install packages {0}', matrix.container) }}
|
||||||
run: |
|
run: |
|
||||||
apk update && apk upgrade && apk add bash git yq ytt
|
apk update && apk upgrade && apk add bash git yq
|
||||||
|
case ${{ matrix.container }} in
|
||||||
|
*:edge) apk add -X http://dl-cdn.alpinelinux.org/alpine/edge/testing ytt ;;
|
||||||
|
esac
|
||||||
# this seems to be needed when running in a container (beause of UID mismatch??)
|
# this seems to be needed when running in a container (beause of UID mismatch??)
|
||||||
git config --global --add safe.directory '*'
|
git config --global --add safe.directory '*'
|
||||||
- name: 'Check out code'
|
- name: 'Check out code'
|
||||||
@@ -26,8 +36,13 @@ jobs:
|
|||||||
- name: ${{ format('YAML check {0}', matrix.container) }}
|
- name: ${{ format('YAML check {0}', matrix.container) }}
|
||||||
shell: bash
|
shell: bash
|
||||||
run: |
|
run: |
|
||||||
for f in $(find . -type f -iname '*.yml'); do
|
for f in $(find . -type f -iname '*.yml' | LC_ALL=C sort); do
|
||||||
echo "===== checking file $f"
|
echo "===== checking file"
|
||||||
|
echo " yq $f"
|
||||||
yq < "$f" > /dev/null
|
yq < "$f" > /dev/null
|
||||||
ytt -f- < "$f" > /dev/null
|
if command -v ytt > /dev/null; then
|
||||||
|
echo " ytt $f"
|
||||||
|
ytt -f- < "$f" > /dev/null
|
||||||
|
fi
|
||||||
done
|
done
|
||||||
|
echo "All done."
|
||||||
|
|||||||
Reference in New Issue
Block a user