-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathvariables.tf
180 lines (153 loc) · 5.04 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
173
174
175
176
177
178
179
// ----------------------------------------------------------------------------
// Required Variables
// ----------------------------------------------------------------------------
variable "gcp_project" {
description = "The name of the GCP project to use"
type = string
}
// ----------------------------------------------------------------------------
// Optional Variables
// ----------------------------------------------------------------------------
variable "cluster_name" {
description = "Name of the Kubernetes cluster to create"
type = string
default = ""
}
variable "cluster_location" {
description = "The location (region or zone) in which the cluster master will be created. If you specify a zone (such as us-central1-a), the cluster will be a zonal cluster with a single cluster master. If you specify a region (such as us-west1), the cluster will be a regional cluster with multiple masters spread across zones in the region"
type = string
default = "us-central1-a"
}
variable "resource_labels" {
description = "Set of labels to be applied to the cluster"
type = map(string)
default = {}
}
// ----------------------------------------------------------------------------
// cluster configuration
// ----------------------------------------------------------------------------
variable "master_authorized_networks" {
type = list(object({ cidr_block = string, display_name = string }))
description = "List of master authorized networks. If none are provided, disallow external access (except the cluster node IPs, which GKE automatically allowlists)."
default = [
{
"cidr_block" = "0.0.0.0/0",
"display_name" = "any"
},
]
}
variable "node_machine_type" {
description = "Node type for the Kubernetes cluster"
type = string
default = "n1-standard-4"
}
variable "initial_cluster_node_count" {
description = "initial number of cluster nodes"
type = number
default = 3
}
variable "initial_primary_node_pool_node_count" {
description = "initial number of pool nodes"
type = number
default = 1
}
variable "autoscaler_min_node_count" {
description = "Minimum number of cluster nodes"
type = number
default = 3
}
variable "autoscaler_max_node_count" {
description = "Maximum number of cluster nodes"
type = number
default = 5
}
variable "autoscaler_location_policy" {
description = "location policy for primary node pool"
type = string
default = "ANY"
}
variable "node_disk_size" {
description = "Node disk size in GB"
type = string
default = "100"
}
variable "node_disk_type" {
description = "Node disk type, either pd-standard or pd-ssd"
type = string
default = "pd-standard"
}
variable "force_destroy" {
description = "Flag to determine whether storage buckets get forcefully destroyed"
type = bool
default = false
}
variable "delete_protect" {
description = "Flag to enable terraform destroy"
type = bool
default = false
}
variable "node_preemptible" {
description = "Use preemptible nodes"
type = bool
default = false
}
variable "node_spot" {
description = "Use spot nodes"
type = bool
default = false
}
// ----------------------------------------------------------------------------
// Ingress
// ----------------------------------------------------------------------------
variable "apex_domain" {
description = "The apex / parent domain to be allocated to the cluster"
type = string
default = ""
}
variable "tls_email" {
description = "Email used by Let's Encrypt. Required for TLS when parent_domain is specified"
type = string
default = ""
}
variable "lets_encrypt_production" {
description = "Flag to determine wether or not to use the Let's Encrypt production server."
type = bool
default = true
}
variable "gsm" {
description = "Enables Google Secrets Manager, not available with JX2"
type = bool
default = false
}
variable "jx_git_url" {
description = "URL for the Jenins X cluster git repository"
type = string
}
variable "jx_bot_username" {
description = "Bot username used to interact with the Jenkins X cluster git repository"
type = string
}
variable "jx_bot_token" {
description = "Bot token used to interact with the Jenkins X cluster git repository"
type = string
}
variable "subdomain" {
description = "Optional sub domain for the installation"
type = string
default = ""
}
variable "apex_domain_gcp_project" {
description = "The GCP project the parent domain is managed by, used to write recordsets for a subdomain if set. Defaults to current project."
type = string
default = ""
}
variable "apex_domain_integration_enabled" {
description = "Add recordsets from a subdomain to a parent / apex domain"
type = bool
default = true
}
variable "kuberhealthy" {
description = "Enables Kuberhealthy helm installation"
type = bool
default = false
}