Move split secrets into single env file
Separating state secrets and others made life a pain. Just do everything in an env file instead, which makes syncing a lot simpler
This commit is contained in:
parent
61072ddeab
commit
c354085dfc
3 changed files with 7 additions and 6 deletions
3
.gitignore
vendored
3
.gitignore
vendored
|
@ -150,5 +150,4 @@ override.tf.json
|
||||||
|
|
||||||
# End of https://www.gitignore.io/api/terraform
|
# End of https://www.gitignore.io/api/terraform
|
||||||
|
|
||||||
terraform/secrets.auto.tfvars
|
.env
|
||||||
terraform/secrets.sh
|
|
||||||
|
|
|
@ -1,9 +1,12 @@
|
||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
set -ex
|
set -e
|
||||||
|
|
||||||
cd terraform/
|
cd terraform/
|
||||||
|
|
||||||
source secrets.sh || true
|
# Load secrets from env file (if it exists)
|
||||||
|
set -a
|
||||||
|
source ./.env || true
|
||||||
|
set +a -x
|
||||||
|
|
||||||
terraform $@
|
terraform $@
|
||||||
|
|
|
@ -4,5 +4,4 @@ set -ex
|
||||||
|
|
||||||
cd terraform/
|
cd terraform/
|
||||||
|
|
||||||
bw get attachment secrets.sh --itemid c4f8b44e-ae62-442d-a9e0-02d0621c2454
|
bw get attachment .env --itemid c4f8b44e-ae62-442d-a9e0-02d0621c2454
|
||||||
bw get attachment secrets.auto.tfvars --itemid c4f8b44e-ae62-442d-a9e0-02d0621c2454
|
|
||||||
|
|
Loading…
Reference in a new issue