Makefile: remove hardcoded environment
This commit is contained in:
parent
048f29c9f1
commit
09e7c060b8
6
Makefile
6
Makefile
|
@ -62,7 +62,7 @@ infra/backend/$(ENVIRONMENT).tfstate: \
|
|||
$(OUT_DIR)/terraform \
|
||||
$(OUT_DIR)/sops \
|
||||
infra/backend/.terraform
|
||||
$(SOPS) exec-env secrets/production.enc.env '\
|
||||
$(SOPS) exec-env secrets/$(ENVIRONMENT).enc.env '\
|
||||
env -C infra/backend \
|
||||
$(TERRAFORM) apply \
|
||||
-var environment=$(ENVIRONMENT) \
|
||||
|
@ -76,7 +76,7 @@ config/$(ENVIRONMENT).tfbackend: | \
|
|||
$(OUT_DIR)/sops \
|
||||
# File is not committed and this has no shared state
|
||||
$(MAKE) infra/backend/$(ENVIRONMENT).tfstate
|
||||
$(SOPS) exec-env secrets/production.enc.env '\
|
||||
$(SOPS) exec-env secrets/$(ENVIRONMENT).enc.env '\
|
||||
env -C infra/backend \
|
||||
$(TERRAFORM) \
|
||||
output -state ../../$< \
|
||||
|
@ -88,7 +88,7 @@ apply: \
|
|||
$(OUT_DIR)/terraform \
|
||||
$(OUT_DIR)/sops \
|
||||
infra/main/.terraform
|
||||
$(SOPS) exec-env secrets/production.enc.env '\
|
||||
$(SOPS) exec-env secrets/$(ENVIRONMENT).enc.env '\
|
||||
env -C infra/main \
|
||||
$(TERRAFORM) apply \
|
||||
-var environment=$(ENVIRONMENT) \
|
||||
|
|
Loading…
Reference in New Issue