Files
kube-prometheus/build.sh
Joshua Olson 4099a04cc0 minor whitespace change
Trying to get travis-ci build to pass for "git diff --exit-code" command
2018-08-22 09:09:01 -05:00

17 lines
535 B
Bash
Executable File

#!/usr/bin/env bash
# This script uses arg $1 (name of *.jsonnet file to use) to generate the manifests/*.yaml files.
set -e
set -x
# only exit with zero if all commands of the pipeline exit successfully
set -o pipefail
# Make sure to start with a clean 'manifests' dir
rm -rf manifests
mkdir manifests
# optional, but we would like to generate yaml, not json
jsonnet -J vendor -m manifests "${1-example.jsonnet}" | xargs -I{} sh -c 'cat {} | gojsontoyaml > {}.yaml; rm -f {}' -- {}