dependabot: Trying usage with Helm too :)

This commit is contained in:
2025-06-10 16:17:35 +02:00
parent adb8a85739
commit 8aecd880fc
3 changed files with 31 additions and 1 deletions

View File

@@ -10,7 +10,7 @@ tmpfile=$(mktemp)
# Make sure to cleanup our temp file on any kind of exit
trap 'rm -f "$tmpfile"' EXIT
# dependabot.yml header
# dependabot.yml docker header
cat > "$tmpfile" <<'YAML'
version: 2
updates:
@@ -28,6 +28,23 @@ find docker -name 'docker-compose.yml' -print0 \
| while read -r dir; do
echo " - \"/$dir\"" >> "$tmpfile"
done
# dependabot.yml helm header
cat >> "$tmpfile" <<'YAML'
- package-ecosystem: "helm"
schedule:
interval: weekly
directories:
YAML
# Find and sort all release.yaml directories
find kubernetes -name 'release.yaml' -print0 \
| xargs -0 -n1 dirname \
| sed 's|^\./||' \
| sort \
| while read -r dir; do
echo " - \"/$dir\"" >> "$tmpfile"
done
# Overwrite file on change
if ! [ -f .github/dependabot.yml ] || ! cmp -s "$tmpfile" .github/dependabot.yml; then