github.com/dahs81/otto@v0.2.1-0.20160126165905-6400716cf085/builtin/foundation/consul/data/aws-vpc-public-private/deploy/main.tf (about) 1 provider "aws" { 2 access_key = "${var.aws_access_key}" 3 secret_key = "${var.aws_secret_key}" 4 region = "${var.region}" 5 } 6 7 module "consul-1" { 8 source = "./module-aws" 9 10 index = "1" 11 private-ip = "10.0.1.8" 12 ami = "${var.ami}" 13 key-name = "${var.key_name}" 14 subnet-id = "${var.subnet-private}" 15 vpc-id = "${var.vpc_id}" 16 join_addr = "10.0.1.6" 17 bastion_host = "${var.bastion_host}" 18 bastion_user = "${var.bastion_user}" 19 } 20 21 module "consul-2" { 22 source = "./module-aws" 23 24 index = "2" 25 private-ip = "10.0.1.7" 26 ami = "${var.ami}" 27 key-name = "${var.key_name}" 28 subnet-id = "${var.subnet-private}" 29 vpc-id = "${var.vpc_id}" 30 join_addr = "10.0.1.6" 31 bastion_host = "${var.bastion_host}" 32 bastion_user = "${var.bastion_user}" 33 } 34 35 module "consul-3" { 36 source = "./module-aws" 37 38 index = "3" 39 private-ip = "10.0.1.6" 40 ami = "${var.ami}" 41 key-name = "${var.key_name}" 42 subnet-id = "${var.subnet-private}" 43 vpc-id = "${var.vpc_id}" 44 join_addr = "10.0.1.6" 45 bastion_host = "${var.bastion_host}" 46 bastion_user = "${var.bastion_user}" 47 } 48 49 output "consul_address" { 50 value = "${module.consul-3.address}" 51 }