-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathvariables.tf
More file actions
203 lines (172 loc) · 5.26 KB
/
Copy pathvariables.tf
File metadata and controls
203 lines (172 loc) · 5.26 KB
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
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
variable "location" {
description = "Location of resource(s)."
type = string
}
variable "contributors" {
description = "List of service principal ID to have Contributor role for the PostgreSQL Flexible Server."
type = list(string)
default = []
}
variable "users_on_keyvault" {
description = "List of object ID (user, service principal or security group in the AD tenant) to have predifined user-like required access to kv."
type = list(string)
default = []
}
variable "terraformers_on_keyvault" {
description = "List of object ID (user, service principal or security group in the AD tenant) to have predifined terraform-like required access to kv."
type = list(string)
default = []
}
variable "pg_version" {
description = "Postgresql engine version"
type = string
default = "13"
}
variable "administrator_login" {
description = "Postgresql admin name"
type = string
default = "psqladmin"
}
variable "sku_name" {
description = "Postgresql vm size"
type = string
default = "GP_Standard_D2s_v3"
}
variable "storage_mb" {
description = "Postgresql size storage in megabytes"
type = number
default = 32768
}
variable "resource_group_name" {
description = "Resource group name."
type = string
}
variable "vnet_resource_group_name" {
description = "VNET Resource group name"
type = string
}
variable "tenant_id" {
description = "Tenant ID."
type = string
}
variable "create_subnet" {
description = "Create Subnet for PostgreSQL Flexible Server."
type = bool
default = false
}
variable "delegated_subnet_id" {
description = "Delegated Subnet ID for PostgreSQL Flexible Server."
type = string
default = ""
}
variable "virtual_network_name" {
description = "Virtual Network Name where Subnet will be created."
type = string
}
variable "virtual_network_id" {
description = "Virtual Network ID where Subnet will be created."
type = string
}
variable "virtual_network_pipeline_id" {
description = "Virtual Network ID where Subnet will be created."
type = string
default = null
}
variable "name" {
description = "Name for the PostgreSQL Flexible Server. This is also used as default for DNS private zone, keyvault and snet names."
type = string
}
variable "private_dns_zone_name_prefix" {
description = "Private DNS private zone name prefix, if undefined then `name` is used"
type = string
default = null
}
variable "subnet_name_prefix" {
description = "Subnet name prefix, if undefined then `name` is used"
type = string
default = null
}
variable "subnet_address_prefixes" {
description = "Address prefixes of Subnet to be created."
type = list(string)
}
variable "keyvault_name_prefix" {
description = "Keyvault name prefix, if undefined then `name` is used"
type = string
default = null
}
variable "public_network_access_enabled" {
description = "Is public network access enabled on the PostgreSQL Flexible Server."
type = bool
default = false
}
variable "backup_retention_days" {
description = "Backup retention days for the PostgreSQL Flexible Server."
type = number
default = 35
}
variable "geo_redundant_backup_enabled" {
description = "(Optional) Is Geo-Redundant backup enabled on the PostgreSQL Flexible Server. Defaults to false. Changing this forces a new PostgreSQL Flexible Server to be created."
type = bool
default = false
}
variable "zone" {
description = "(Optional) Specifies the Availability Zone in which the PostgreSQL Flexible Server should be located."
type = string
default = ""
}
variable "maintenance_window" {
description = "Cron maintenance window (default sunday 23:59."
type = object({
day_of_week = number
start_hour = number
start_minute = number
})
default = {
day_of_week = 0
start_hour = 23
start_minute = 59
}
}
variable "postgresql_config" {
type = map(string)
default = {
max_connections = ""
shared_buffers = ""
effective_cache_size = ""
maintenance_work_mem = ""
checkpoint_completion_target = ""
wal_buffers = ""
default_statistics_target = ""
random_page_cost = ""
effective_io_concurrency = ""
work_mem = ""
min_wal_size = ""
max_wal_size = ""
max_worker_processes = ""
max_parallel_workers_per_gather = ""
max_parallel_workers = ""
max_parallel_maintenance_workers = ""
"azure.extensions" = ""
}
}
variable "instance_lock" {
description = "If true, it’s not possible to remove the flexible-server"
type = bool
default = true
}
variable "tags" {
description = "A map of tags to assign to the resources"
type = map(string)
default = {}
}
variable "logs_activation" {
description = "If ON, logs are enabled"
type = string
default = "ON"
}
variable "logs_retention" {
description = "Number of days to keep logs"
type = number
default = 3
}