fix for the selfmade yaml2json

This commit is contained in:
Sebastian
2025-01-15 05:44:35 +01:00
parent 78bab70a05
commit 74e85c0698

View File

@@ -10,11 +10,11 @@ while IFS= read -r line; do
done < "$BASEPATH/path-blacklist.txt"
# Parse Docker Compose file to get all services
services=$(cat $BASEPATH/$1.yml | yaml2json | jq -r '.services | keys | .[]')
services=$(cat $BASEPATH/$1.yml | yaml2json - | jq -r '.services | keys | .[]')
for service in $services; do
labels=($(cat "$BASEPATH/$1.yml" | yaml2json | jq -r ".services[\"$service\"].labels[]"))
labels=($(cat "$BASEPATH/$1.yml" | yaml2json - | jq -r ".services[\"$service\"].labels[]"))
for label in "${labels[@]}"; do
if [[ "$label" == *"stripprefix.prefixes"* ]]; then