github.com/bigcommerce/nomad@v0.9.3-bc/e2e/terraform/README.md (about) 1 Terraform provisioner for end to end tests 2 ========================================== 3 4 This folder contains terraform resources for provisioning a nomad cluster on AWS for end to end tests. 5 It uses a Nomad binary identified by its commit SHA that's stored in a shared s3 bucket that Nomad team 6 developers can access. The commit SHA can be from any branch that's pushed to remote. 7 8 Use [envchain](https://github.com/sorah/envchain) to store your AWS credentials. 9 10 11 ``` 12 $ cd e2e/terraform/ 13 $ TF_VAR_nomad_sha=<nomad_sha> envchain nomadaws terraform apply 14 ``` 15 16 After this step, you should have a nomad client address to point the end to end tests in the `e2e` folder to. 17 18 ## SSH 19 20 Terraform will output node IPs that may be accessed via ssh: 21 22 ``` 23 ssh -i keys/nomad-e2e-*.pem ubuntu@${EC2_IP_ADDR} 24 ``` 25 26 27 ## Teardown 28 The terraform state file stores all the info, so the nomad_sha doesn't need to be valid during teardown. 29 30 ``` 31 $ cd e2e/terraform/ 32 $ envchain nomadaws TF_VAR_nomad_sha=yyyzzz terraform destroy 33 ```