1234567891011121314151617181920212223 |
- #! /bin/bash
- #
- # Runs an init and apply in all copies of a module
- #
- # TODO: Would be really nice if this did some input validation, and if you
- # could specify 'local' or not.
- for i in $( find . -type d -name "$1" -print | egrep -v "000-skeleton" ); do
- echo ""
- echo ------------------------------------
- echo Processing $i...
- echo ------------------------------------
- pushd $i
- if [[ -f "../UNUSED.ACCOUNT" ]]; then
- echo $i is unused. Continuing.
- popd
- continue
- fi
- #echo terragrunt init && echo terragrunt apply
- terragrunt init && terragrunt apply
- popd
- done
|