Revision 95c1e72d7640528ee7013d414168e98b155424bc authored by Martynas Pumputis on 21 July 2023, 12:45:19 UTC, committed by Martynas Pumputis on 21 July 2023, 12:45:19 UTC
Signed-off-by: Martynas Pumputis <m@lambda.lt>
1 parent 8053488
check-examples.sh
#!/usr/bin/env bash
set -o errexit
set -o nounset
set -o pipefail
script_dir="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
source_dir="$(cd "${script_dir}/.." && pwd)"
examples_dir="${source_dir}/examples"
cilium="${source_dir}/cilium/cilium"
JSON_FILES=$(find ${examples_dir} \
-wholename "*/policies/*.json" \
-o -wholename "*/demo/*.json")
YAML_FILES=$(find ${examples_dir}/policies -name "*.yaml")
for f in $JSON_FILES; do
${cilium} policy validate --verbose=false "$f"
done
for f in $YAML_FILES; do
yamllint -c "$script_dir/yaml.config" "$f"
done
![swh spinner](/static/img/swh-spinner.gif)
Computing file changes ...