~nromdotcom/gemif

gemif/scripts/deploy_terraform.sh -rwxr-xr-x 468 bytes
85dc63b9Norm MacLennan chore: upgrade linters and fix linting issues 10 months ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#!/usr/bin/env sh
set -e

git_tag=`git describe --exact-match 2> /dev/null || echo ""`
if [ "$git_tag" != "" ]; then
  cd ./infra
  terraform0.14 init -backend=true \
    -backend-config bucket=$TFSTATE_BUCKET \
    -backend-config region=us-east-1 \
    -backend-config key=gemif \
    -backend-config encrypt=true \
    -input=false

  terraform0.14 apply -auto-approve -input=false -var gemif_version=$git_tag
else
  echo "not a tagged commit, nothing to deploy"
fi