-
Notifications
You must be signed in to change notification settings - Fork 8
/
_variables.tf
172 lines (150 loc) · 4.11 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
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
variable "cidr_block" {
type = string
description = "IPV4 range for VPC Creation"
default = "10.20.0.0/20"
}
variable "subnet" {
description = "Subnet details having zone and cidr address"
type = map(object({
is_public = bool
nat_gateway = bool
details = list(object({
availability_zone = string
cidr_address = string
}))
}))
default = {}
}
variable "subnet_bits" {
type = number
description = "Number Bits required for creating Subnets"
default = 8
}
variable "max_subnet_az" {
type = number
description = "Maximum number of Subnets per Availability Zone"
default = 2
}
variable "subnet_group" {
type = map(object({
is_public = bool
nat_gateway = bool
}))
description = "Subnets group divided into public, private and database"
default = {
"database" = {
is_public = false
nat_gateway = false
},
"private" = {
is_public = false
nat_gateway = true
},
"public" = {
is_public = true
nat_gateway = false
}
}
}
variable "additional_subnet_group" {
description = "Subnet details having zone and cidr address"
type = map(object({
is_public = bool
nat_gateway = bool
details = list(object({
availability_zone = string
cidr_address = string
}))
}))
default = {}
}
variable "enable_dns_support" {
type = bool
description = "A boolean flag to enable/disable DNS support in the VPC"
default = true
}
variable "enable_dns_hostnames" {
type = bool
description = "A boolean flag to enable/disable DNS hostnames in the VPC"
default = true
}
variable "name" {
type = string
description = "A string value to describe prefix of all the resources"
default = ""
}
variable "default_tags" {
type = map(string)
description = "A map to add common tags to all the resources"
default = {
"Scope" : "VPC"
"CreatedBy" : "Terraform"
}
}
variable "common_tags" {
type = map(string)
description = "A map to add common tags to all the resources"
default = {}
}
variable "create_peering_routes" {
type = bool
description = "True/False value need to create Peering Route or not, Default to false"
default = false
}
variable "routes" {
description = "Route details having destination and target address"
type = map(object({
peering = map(string)
}))
default = {}
}
variable "secondary_cidr_blocks" {
description = "List of secondary CIDR blocks to associate with the VPC to extend the IP Address pool"
type = list(string)
default = []
}
variable "enable_flow_log" {
description = "Whether or not to enable VPC Flow Logs"
type = bool
default = false
}
variable "flow_log_cloudwatch_log_group_retention_in_days" {
description = "Specifies the number of days you want to retain log events in the specified log group for VPC flow logs."
type = number
default = 7
}
variable "flow_log_destination_type" {
description = "Type of flow log destination. Can be s3 or cloud-watch-logs."
type = string
default = "cloud-watch-logs"
}
variable "flow_log_log_format" {
description = "The fields to include in the flow log record, in the order in which they should appear."
type = string
default = null
}
variable "flow_log_traffic_type" {
description = "The type of traffic to capture. Valid values: ACCEPT, REJECT, ALL."
type = string
default = "ALL"
}
variable "flow_log_max_aggregation_interval" {
description = "The maximum interval of time during which a flow of packets is captured and aggregated into a flow log record. Valid Values: `60` seconds or `600` seconds."
type = number
default = 600
}
variable "create_vpc_endpoint" {
type = bool
description = "Create all VPC Endpoint"
default = false
}
variable "add_interface" {
type = list(string)
description = "Adding new Interface endpoints"
default = []
}
variable "add_gateway" {
type = list(string)
description = "Adding new Gateway endpoints"
default = []
}