2020-04-13 14:25:24 +00:00
|
|
|
NOMAD_SHA ?= $(shell git rev-parse HEAD)
|
2020-04-28 20:15:58 +00:00
|
|
|
PKG_PATH = $(shell pwd)/../../pkg/linux_amd64/nomad
|
2020-04-09 14:54:30 +00:00
|
|
|
|
2021-01-22 14:18:17 +00:00
|
|
|
# The version of nomad that gets deployed depends on an order of precedence
|
|
|
|
# linked below
|
2021-03-08 13:50:13 +00:00
|
|
|
# https://github.com/hashicorp/nomad/blob/main/e2e/terraform/README.md#nomad-version
|
2020-04-09 14:54:30 +00:00
|
|
|
dev-cluster:
|
2020-09-18 15:27:24 +00:00
|
|
|
terraform apply -auto-approve \
|
2020-10-29 13:15:22 +00:00
|
|
|
-var="nomad_sha=$(NOMAD_SHA)"
|
2020-09-18 15:27:24 +00:00
|
|
|
terraform output environment
|
2020-04-09 14:54:30 +00:00
|
|
|
|
2020-04-28 20:15:58 +00:00
|
|
|
dev-cluster-from-local:
|
2020-09-18 15:27:24 +00:00
|
|
|
terraform apply -auto-approve \
|
2020-10-29 13:15:22 +00:00
|
|
|
-var="nomad_local_binary=$(PKG_PATH)"
|
2020-09-18 15:27:24 +00:00
|
|
|
terraform output environment
|
2020-04-28 20:15:58 +00:00
|
|
|
|
2020-04-09 14:54:30 +00:00
|
|
|
clean:
|
|
|
|
terraform destroy -auto-approve
|
2020-09-18 15:27:24 +00:00
|
|
|
|
|
|
|
full-cluster:
|
|
|
|
terraform apply -auto-approve \
|
2020-10-29 13:15:22 +00:00
|
|
|
-var-file=terraform.full.tfvars \
|
|
|
|
-var="nomad_sha=$(NOMAD_SHA)"
|
2020-09-18 15:27:24 +00:00
|
|
|
|
|
|
|
plan-dev-cluster:
|
|
|
|
terraform plan \
|
2020-10-29 13:15:22 +00:00
|
|
|
-var="nomad_sha=$(NOMAD_SHA)"
|
2020-09-18 15:27:24 +00:00
|
|
|
|
|
|
|
plan-full-cluster:
|
|
|
|
terraform plan \
|
2020-10-29 13:15:22 +00:00
|
|
|
-var-file=terraform.full.tfvars \
|
|
|
|
-var="nomad_sha=$(NOMAD_SHA)"
|