-
Notifications
You must be signed in to change notification settings - Fork 7
/
Copy pathvariables.tf
99 lines (82 loc) · 2.33 KB
/
variables.tf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
variable "account_name" {
description = "A common account name"
type = string
}
variable "sns_topic_name" {
description = "Name of an SNS topic to create for cloudwatch alarms"
type = string
default = "vpc_alerts"
}
variable "additional_vpc_tags" {
type = map(string)
default = {}
}
variable "additional_subnet_tags" {
type = map(string)
default = {}
}
variable "cidr" {
description = "The CIDR block to be associated to the VPC"
type = string
}
variable "environment" {
description = "Name for this environment. e.g. staging"
type = string
}
variable "common_tags" {
description = "Map of common tags to add to every resource"
type = map(string)
}
variable "zone" {
description = "A list of zomes used for this deployment"
type = list(string)
}
variable "internal_dns_zone" {
description = "Zone to define for internal name resolution"
type = string
default = "internal.cloud"
}
variable "vpc_endpoint_cloudwatch_enabled" {
description = "Boolean to turn on/off cloudwatch endpoint"
type = number
default = 0
}
variable "vpc_endpoint_cloudwatch_log_enabled" {
description = "Boolean to turn on/off cloudwatch logs endpoint"
type = number
default = 0
}
variable "vpc_endpoint_ec2_enabled" {
description = "Boolean to turn on/off ec2 endpoint"
type = number
default = 0
}
variable "vpc_endpoint_sqs_enabled" {
description = "Boolean to turn on/off sqs endpoint"
type = number
default = 0
}
variable "vpc_endpoint_s3_enabled" {
description = "Boolean to turn on/off s3 endpoint"
type = number
default = 0
}
variable "vpc_endpoint_ssm_enabled" {
description = "Boolean to turn on/off ssm endpoint"
type = number
default = 0
}
variable "vpc_endpoint_dynamodb_enabled" {
description = "Boolean to turn on/off dynamodb endpoint"
type = number
default = 0
}
variable "subnet_map_public_ip_on_launch" {
description = "Whether public subnets should allocate a public ip when instances launch"
type = bool
default = true
}
locals {
public_cidrs = [cidrsubnet(var.cidr, 3, 0), cidrsubnet(var.cidr, 3, 1), cidrsubnet(var.cidr, 3, 2)]
private_cidrs = [cidrsubnet(var.cidr, 3, 3), cidrsubnet(var.cidr, 3, 4), cidrsubnet(var.cidr, 3, 5)]
}