You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is it possible to add yq to the generated image. We are planning to use this for validating manfiseste using kustomize/kubeconform and that script uses yq.
Script is attached blow for reference
#!/usr/bin/env bash
set -eo pipefail
find . -type f -name '*.yaml' -print0 | while IFS= read -r -d $'\0' file;
do
yq e 'true' "$file" > /dev/null || error_exit "found when validating file $file"
done
k="kustomization.yaml"
kustomize_flags="--load-restrictor=LoadRestrictionsNone"
find . -type f -name $k -print0 | while IFS= read -r -d $'\0' file;
do
[[ $file == ./base/* ]] && continue
echo "================================"
echo "INFO - Validating kustomization ${file/%$k} with kubeconform"
kustomize build "${file/%$k}" $kustomize_flags | kubeconform -exit-on-error -kubernetes-version 1.21.2 -strict -ignore-missing-schemas -schema-location default -schema-location 'policy/{{ .ResourceKind }}{{ .KindSuffix }}.json' --verbose
done
The text was updated successfully, but these errors were encountered:
Is it possible to add
yq
to the generated image. We are planning to use this for validating manfiseste using kustomize/kubeconform and that script uses yq.Script is attached blow for reference
The text was updated successfully, but these errors were encountered: