Compare commits
8 Commits
526fc6dfec
...
generic-de
| Author | SHA1 | Date | |
|---|---|---|---|
| fb667e69bd | |||
|
577d6d9288
|
|||
| 83f23d6f4a | |||
| ef6c469f6c | |||
| 28e6783d73 | |||
| f7b6037ffc | |||
|
3941d174a8
|
|||
| f693b7f16f |
@@ -17,7 +17,63 @@ env:
|
|||||||
BASE_BRANCH: "origin/${{ gitea.base_ref }}"
|
BASE_BRANCH: "origin/${{ gitea.base_ref }}"
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
lint-test:
|
chart-testing:
|
||||||
|
runs-on: ubuntu-js
|
||||||
|
steps:
|
||||||
|
- name: Checkout
|
||||||
|
uses: actions/checkout@v6
|
||||||
|
with:
|
||||||
|
fetch-depth: 0
|
||||||
|
|
||||||
|
- name: Set up Helm
|
||||||
|
uses: azure/setup-helm@v4
|
||||||
|
with:
|
||||||
|
token: ${{ secrets.GITEA_TOKEN }}
|
||||||
|
version: v3.19.2
|
||||||
|
|
||||||
|
- name: Set up Node.js
|
||||||
|
uses: actions/setup-node@v6
|
||||||
|
with:
|
||||||
|
node-version: '24'
|
||||||
|
|
||||||
|
- name: Set up Python
|
||||||
|
uses: actions/setup-python@v6
|
||||||
|
with:
|
||||||
|
python-version: '3.14'
|
||||||
|
|
||||||
|
- name: Set up Chart Testing
|
||||||
|
uses: helm/chart-testing-action@v2.7.0
|
||||||
|
with:
|
||||||
|
yamale_version: "6.0.0"
|
||||||
|
|
||||||
|
- name: Run Chart Testing (list-changed)
|
||||||
|
id: list-changed
|
||||||
|
run: |
|
||||||
|
changed=$(ct list-changed --target-branch ${{ gitea.event.repository.default_branch }})
|
||||||
|
if [[ -n "$changed" ]]; then
|
||||||
|
echo "changed=true" >> $GITHUB_OUTPUT
|
||||||
|
fi
|
||||||
|
|
||||||
|
- name: Run Chart Testing (lint)
|
||||||
|
if: steps.list-changed.outputs.changed == 'true'
|
||||||
|
run: ct lint --validate-maintainers=false --target-branch ${{ gitea.event.repository.default_branch }}
|
||||||
|
|
||||||
|
- name: ntfy Failed
|
||||||
|
uses: niniyas/ntfy-action@master
|
||||||
|
if: failure()
|
||||||
|
with:
|
||||||
|
url: '${{ secrets.NTFY_URL }}'
|
||||||
|
topic: '${{ secrets.NTFY_TOPIC }}'
|
||||||
|
title: 'Test Failure - Helm Charts'
|
||||||
|
priority: 3
|
||||||
|
headers: '{"Authorization": "Bearer ${{ secrets.NTFY_CRED }}"}'
|
||||||
|
tags: action,failed
|
||||||
|
details: 'Tests have failed for Helm Charts'
|
||||||
|
icon: 'https://cdn.jsdelivr.net/gh/selfhst/icons/png/gitea.png'
|
||||||
|
actions: '[{"action": "view", "label": "Open Gitea", "url": "https://gitea.alexlebens.dev/alexlebens/helm-charts/actions?workflow=lint-test.yaml", "clear": true}]'
|
||||||
|
image: true
|
||||||
|
|
||||||
|
lint-helm:
|
||||||
runs-on: ubuntu-js
|
runs-on: ubuntu-js
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
@@ -36,7 +92,13 @@ jobs:
|
|||||||
id: branch-exists
|
id: branch-exists
|
||||||
if: github.event_name == 'push' || steps.check-branch-exists.outputs.exists == 'true' && github.event_name == 'pull_request'
|
if: github.event_name == 'push' || steps.check-branch-exists.outputs.exists == 'true' && github.event_name == 'pull_request'
|
||||||
run: |
|
run: |
|
||||||
echo ">> Branch ${{ gitea.base_ref }} exists, will continue with linting"
|
if [ ${{ github.event_name == 'push' }} ]; then
|
||||||
|
echo ">> Action is from a push event, will continue with linting"
|
||||||
|
|
||||||
|
else
|
||||||
|
echo ">> Branch ${{ gitea.base_ref }} exists, will continue with linting"
|
||||||
|
|
||||||
|
fi
|
||||||
|
|
||||||
echo "----"
|
echo "----"
|
||||||
|
|
||||||
@@ -44,20 +106,11 @@ jobs:
|
|||||||
|
|
||||||
- name: Set up Helm
|
- name: Set up Helm
|
||||||
uses: azure/setup-helm@v4
|
uses: azure/setup-helm@v4
|
||||||
|
if: steps.branch-exists.outputs.exists == 'true'
|
||||||
with:
|
with:
|
||||||
token: ${{ secrets.GITEA_TOKEN }}
|
token: ${{ secrets.GITEA_TOKEN }}
|
||||||
version: v3
|
version: v3
|
||||||
|
|
||||||
- name: Set up Python
|
|
||||||
uses: actions/setup-python@v6
|
|
||||||
with:
|
|
||||||
python-version: '3.14'
|
|
||||||
|
|
||||||
- name: Set up Chart Testing
|
|
||||||
uses: helm/chart-testing-action@v2.8.0
|
|
||||||
with:
|
|
||||||
yamale_version: "6.0.0"
|
|
||||||
|
|
||||||
- name: Check Directories for Changes
|
- name: Check Directories for Changes
|
||||||
id: check-dir-changes
|
id: check-dir-changes
|
||||||
if: steps.branch-exists.outputs.exists == 'true'
|
if: steps.branch-exists.outputs.exists == 'true'
|
||||||
@@ -83,6 +136,7 @@ jobs:
|
|||||||
|
|
||||||
for path in $GIT_DIFF; do
|
for path in $GIT_DIFF; do
|
||||||
CHANGED_CHARTS+=$(echo "$path" | awk -F '/' '{print $2}')
|
CHANGED_CHARTS+=$(echo "$path" | awk -F '/' '{print $2}')
|
||||||
|
CHANGED_CHARTS+=$(echo " ")
|
||||||
done
|
done
|
||||||
|
|
||||||
else
|
else
|
||||||
@@ -94,13 +148,13 @@ jobs:
|
|||||||
if [ -n "${CHANGED_CHARTS}" ]; then
|
if [ -n "${CHANGED_CHARTS}" ]; then
|
||||||
echo ""
|
echo ""
|
||||||
echo ">> Chart to Lint:"
|
echo ">> Chart to Lint:"
|
||||||
echo "$(echo "${CHANGED_CHARTS[@]}" | sort -u)"
|
echo "$(echo "${CHANGED_CHARTS}" | sort -u)"
|
||||||
|
|
||||||
echo "----"
|
echo "----"
|
||||||
|
|
||||||
echo "changes-detected=true" >> $GITEA_OUTPUT
|
echo "changes-detected=true" >> $GITEA_OUTPUT
|
||||||
echo "chart-dir<<EOF" >> $GITEA_OUTPUT
|
echo "chart-dir<<EOF" >> $GITEA_OUTPUT
|
||||||
echo "$(echo "${CHANGED_CHARTS[@]}" | sort -u)" >> $GITEA_OUTPUT
|
echo "$(echo "${CHANGED_CHARTS}" | sort -u)" >> $GITEA_OUTPUT
|
||||||
echo "EOF" >> $GITEA_OUTPUT
|
echo "EOF" >> $GITEA_OUTPUT
|
||||||
else
|
else
|
||||||
echo "changes-detected=false" >> $GITEA_OUTPUT
|
echo "changes-detected=false" >> $GITEA_OUTPUT
|
||||||
@@ -156,18 +210,6 @@ jobs:
|
|||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
|
||||||
- name: Run Chart Testing (list-changed)
|
|
||||||
id: list-changed
|
|
||||||
run: |
|
|
||||||
changed=$(ct list-changed --target-branch ${{ gitea.event.repository.default_branch }})
|
|
||||||
if [[ -n "$changed" ]]; then
|
|
||||||
echo "changed=true" >> $GITHUB_OUTPUT
|
|
||||||
fi
|
|
||||||
|
|
||||||
- name: Run Chart Testing (lint)
|
|
||||||
if: steps.list-changed.outputs.changed == 'true'
|
|
||||||
run: ct lint --validate-maintainers=false --target-branch ${{ gitea.event.repository.default_branch }}
|
|
||||||
|
|
||||||
- name: ntfy Failed
|
- name: ntfy Failed
|
||||||
uses: niniyas/ntfy-action@master
|
uses: niniyas/ntfy-action@master
|
||||||
if: failure()
|
if: failure()
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
apiVersion: v2
|
apiVersion: v2
|
||||||
name: generic-device-plugin
|
name: generic-device-plugin
|
||||||
version: 0.20.4
|
version: 0.20.6
|
||||||
description: Generic Device Plugin
|
description: Generic Device Plugin
|
||||||
keywords:
|
keywords:
|
||||||
- generic-device-plugin
|
- generic-device-plugin
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ name: generic-device-plugin
|
|||||||
# -- Default image
|
# -- Default image
|
||||||
image:
|
image:
|
||||||
repository: ghcr.io/squat/generic-device-plugin
|
repository: ghcr.io/squat/generic-device-plugin
|
||||||
tag: latest@sha256:4896ffd516624d6eb7572e102bc4397e91f8bc3b2fb38b5bfefd758baae3dcf2
|
tag: latest@sha256:d64b1c851b534de348bcd3189555a22d3966e6592fc79d2a78abfff4f6c1a2e1
|
||||||
pullPolicy: Always
|
pullPolicy: Always
|
||||||
|
|
||||||
# -- Domain used by devices for identifcation
|
# -- Domain used by devices for identifcation
|
||||||
|
|||||||
Reference in New Issue
Block a user