github.com/hhrutter/nomad@v0.6.0-rc2.0.20170723054333-80c4b03f0705/terraform/aws/env/us-east/main.tf (about) 1 variable "region" { 2 description = "The AWS region to deploy to." 3 default = "us-east-1" 4 } 5 6 variable "ami" {} 7 8 variable "instance_type" { 9 description = "The AWS instance type to use for both clients and servers." 10 default = "t2.medium" 11 } 12 13 variable "key_name" {} 14 15 variable "server_count" { 16 description = "The number of servers to provision." 17 default = "3" 18 } 19 20 variable "client_count" { 21 description = "The number of clients to provision." 22 default = "4" 23 } 24 25 variable "cluster_tag_value" { 26 description = "Used by Consul to automatically form a cluster." 27 default = "auto-join" 28 } 29 30 provider "aws" { 31 region = "${var.region}" 32 } 33 34 module "hashistack" { 35 source = "../../modules/hashistack" 36 37 region = "${var.region}" 38 ami = "${var.ami}" 39 instance_type = "${var.instance_type}" 40 key_name = "${var.key_name}" 41 server_count = "${var.server_count}" 42 client_count = "${var.client_count}" 43 cluster_tag_value = "${var.cluster_tag_value}" 44 } 45 46 output "primary_server_private_ips" { 47 value = "${module.hashistack.primary_server_private_ips}" 48 } 49 50 output "primary_server_public_ips" { 51 value = "${module.hashistack.primary_server_public_ips}" 52 } 53 54 output "client_private_ips" { 55 value = "${module.hashistack.client_private_ips}" 56 } 57 58 output "client_public_ips" { 59 value = "${module.hashistack.client_public_ips}" 60 }