e2e: add a convenient creation script
Add a convenience Makefile for creating e2e environment for manual debugging.
This commit is contained in:
parent
030e40ac5c
commit
8a4937d9ce
|
@ -53,7 +53,7 @@ Then deploy Nomad to the cluster by passing `-provision.terraform`
|
|||
without a Nomad version flag:
|
||||
|
||||
```sh
|
||||
go test -v . -nomad.version=0.10.2 -provision.terraform ./provisioning.json -skipTests
|
||||
NOMAD_E2E=1 go test -v . -nomad.version=0.10.2 -provision.terraform ./provisioning.json -skipTests
|
||||
```
|
||||
|
||||
Because it can take a little while for the cluster to settle, it's
|
||||
|
|
10
e2e/terraform/Makefile
Normal file
10
e2e/terraform/Makefile
Normal file
|
@ -0,0 +1,10 @@
|
|||
NOMAD_SHA := $(shell git rev-parse HEAD)
|
||||
|
||||
dev-cluster:
|
||||
terraform apply -auto-approve -var-file=terraform.tfvars.dev
|
||||
terraform output provisioning | jq . > ../provisioning.json
|
||||
cd .. && NOMAD_E2E=1 go test -v . -nomad.sha=$(NOMAD_SHA) -provision.terraform ./provisioning.json -skipTests
|
||||
terraform output message
|
||||
|
||||
clean:
|
||||
terraform destroy -auto-approve
|
|
@ -132,7 +132,13 @@ go test -v ./e2e
|
|||
|
||||
ssh into nodes with:
|
||||
```
|
||||
ssh -i keys/${local.random_name}.pem ubuntu@${aws_instance.client_linux[0].public_ip}
|
||||
# server
|
||||
ssh -i keys/${local.random_name}.pem ubuntu@${aws_instance.server[0].public_ip}
|
||||
|
||||
# clients
|
||||
%{ for ip in aws_instance.client_linux.*.public_ip ~}
|
||||
ssh -i keys/${local.random_name}.pem ubuntu@${ip}
|
||||
%{ endfor ~}
|
||||
```
|
||||
EOM
|
||||
|
||||
|
|
Loading…
Reference in a new issue