github.com/arunkumar7540/cli@v6.45.0+incompatible/ci/bin/reconfigure-pr-builder (about) 1 #!/usr/bin/env bash 2 3 set -e 4 set -o pipefail 5 6 check_installed() { 7 if ! command -v $1 > /dev/null 2>&1; then 8 printf "$1 must be installed before running this script!" 9 exit 1 10 fi 11 } 12 13 configure_pipeline() { 14 local name=$1 15 local pipeline=$2 16 17 printf "configuring the $name pipeline...\n" 18 19 fly -t ci set-pipeline \ 20 -p $name \ 21 -c $pipeline \ 22 -v cli-pools-github-private-key="$(lpass show Shared-CLI/Concourse/pr-builder-bosh-lite-bool-private-key --notes)" \ 23 -v github-access-token="$(lpass show Shared-CLI/Concourse/pr-builder-access-token --notes)" 24 25 } 26 27 check_installed lpass 28 check_installed fly 29 30 pipelines_path=$(cd $(dirname $0)/.. && pwd) 31 32 configure_pipeline cli-pr-builder $pipelines_path/cli-pr-builder/pipeline.yml 33 34