-
Notifications
You must be signed in to change notification settings - Fork 2
/
variables.tf
172 lines (143 loc) · 5 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
##-----------------------------------------------------------------------------
## AWS Document DB Variables.
##-----------------------------------------------------------------------------
variable "master_password" {
description = "(Required unless a snapshot_identifier is provided) Password for the master DB user. Note that this may show up in logs, and it will be stored in the state file."
type = string
default = ""
}
variable "database_name" {
description = "Name of the database."
type = string
}
variable "master_username" {
type = string
default = "root"
description = "(Required unless a snapshot_identifier is provided) Username for the master DB user."
}
variable "retention_period" {
type = string
default = "7"
description = "Number of days to retain backups for."
}
variable "preferred_backup_window" {
type = string
default = "07:00-09:00"
description = "Daily time range during which the backups happen."
}
variable "skip_final_snapshot" {
type = bool
description = "Determines whether a final DB snapshot is created before the DB cluster is deleted."
default = false
}
variable "apply_immediately" {
type = bool
description = "Specifies whether any cluster modifications are applied immediately, or during the next maintenance window."
default = true
}
variable "storage_encrypted" {
type = bool
description = "Specifies whether the DB cluster is encrypted."
default = true
}
variable "kms_key_id" {
type = string
description = "The ARN for the KMS encryption key. When specifying `kms_key_id`, `storage_encrypted` needs to be set to `true`."
default = ""
}
variable "snapshot_identifier" {
type = string
default = ""
description = "Specifies whether or not to create this cluster from a snapshot. You can use either the name or ARN when specifying a DB cluster snapshot, or the ARN when specifying a DB snapshot."
}
variable "subnet_list" {
description = "List of subnet IDs database instances should deploy into."
type = list(string)
default = [""]
}
variable "cluster_family" {
type = string
default = "docdb5.0"
description = "The family of the DocumentDB cluster parameter group. For more details, see https://docs.aws.amazon.com/documentdb/latest/developerguide/db-cluster-parameter-group-create.html ."
}
variable "engine" {
type = string
default = "docdb"
description = "The name of the database engine to be used for this DB cluster. Defaults to `docdb`. Valid values: `docdb`."
}
variable "engine_version" {
type = string
default = ""
description = "The version number of the database engine to use."
}
variable "enabled_cloudwatch_logs_exports" {
type = list(string)
description = "List of log types to export to cloudwatch. The following log types are supported: audit, error, general, slowquery."
default = ["audit", "profiler"]
}
variable "instance_class" {
type = string
default = "db.t3.medium"
description = "The instance class to use. For more details, see https://docs.aws.amazon.com/documentdb/latest/developerguide/db-instance-classes.html#db-instance-class-specs ."
}
variable "cluster_size" {
type = string
default = "2"
description = "Number of DB instances to create in the cluster"
}
variable "vpc_security_group_ids" {
type = set(string)
default = null
}
variable "ca_cert_identifier" {
type = string
default = null
description = "The identifier of the certificate authority (CA) certificate for the DB instance."
}
variable "parameters" {
type = list(object({
apply_method = optional(string)
name = string
value = string
}))
default = []
description = "A list of DocumentDB parameters to apply. Setting parameters to system default values may show a difference on imported resources."
}
##-----------------------------------------------------------------------------
## Labels variables
##-----------------------------------------------------------------------------
variable "enable" {
type = bool
default = true
description = "Flag to control the documentDB creation."
}
variable "name" {
type = string
default = ""
description = "Name (e.g. `app` or `cluster`)."
}
variable "environment" {
type = string
default = ""
description = "Environment (e.g. `prod`, `dev`, `staging`)."
}
variable "repository" {
type = string
default = "https://github.com/clouddrove/terraform-aws-documentdb"
description = "Terraform current module repo"
}
variable "label_order" {
type = list(any)
default = []
description = "Label order, e.g. `name`,`application`."
}
variable "managedby" {
type = string
default = "hello@clouddrove.com"
description = "ManagedBy, eg 'CloudDrove'"
}
variable "deletion_protection" {
type = bool
default = null
description = "(optional) describe your variable"
}