-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathvars.tf
285 lines (218 loc) · 7 KB
/
vars.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
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
variable "do_api_token" {
description = "DigitalOcean API access token. This can be generated from the DigitalOcean web console."
}
variable "droplet_ssh_user" {
description = "SSH user used by Terraform's 'connection' provisioner to access the droplets."
}
variable "droplet_private_key_file" {
description = "Path to the private key used by Terraform's 'connecton' provisioner to access the droplets."
}
variable "droplet_private_key_id" {
description = "ID of the SSH key used by Terraform to create the droplets. This can be obtained from the DigitalOcean web console or CLI."
}
variable "droplet_region" {
default = "sfo2"
}
variable "droplet_domain" {
default = "droplet.cluster"
description = "All droplets will be assigned FQDN in the form of <name>.<region>.<droplet_domain>."
}
variable "droplet_tls_certs_home" {
default = "/etc/ssl/certs"
}
variable "droplet_maintenance_window_start" {
default = "Sun 1:00"
}
variable "droplet_maintenance_window_length" {
default = "2h"
}
variable "droplet_update_channel" {
default = "stable"
}
variable "coreos_image" {
default = "coreos-stable"
description = "Slug of CoreOS image"
}
variable "coredns_version" {
default = "011"
}
variable "etcd_version" {
default = "3.2.0"
}
variable "etcd_count" {
default = 3
}
variable "etcd_data_dir" {
default = "/var/lib/etcd"
}
variable "etcd_client_port" {
default = 2379
}
variable "etcd_peer_port" {
default = 2380
}
variable "etcd_heartbeat_interval" {
default = 5000
}
variable "etcd_election_timeout" {
default = 25000
}
variable "k8s_version" {
default = "v1.8.0"
}
variable "k8s_cluster_name" {
default = "do-k8s"
}
variable "k8s_cluster_dns_ip" {
default = "10.32.0.10"
}
variable "k8s_cluster_domain" {
default = "kubernetes.internal"
}
variable "k8s_cluster_cidr" {
default = "10.244.0.0/22"
}
variable "k8s_service_cluster_ip_range" {
default = "10.32.0.0/24"
}
variable "k8s_service_node_port_range" {
default = "30000-32767"
}
variable "k8s_apiserver_count" {
default = 1
}
variable "k8s_apiserver_insecure_port" {
default = 8080
}
variable "k8s_apiserver_secure_port" {
default = 6443
}
variable "k8s_apiserver_encryption_key" {
description = "Encryption key used in the API server's encryption config"
}
variable "k8s_apiserver_encryption_config_file" {
default = "/opt/k8s/encryption-config.yaml"
}
variable "tls_cacert_file" {
default = "cacert.pem"
}
variable "tls_cakey_file" {
default = "cakey.pem"
}
variable "tls_key_file" {
default = "key.pem"
}
variable "tls_cert_file" {
default = "cert.pem"
}
variable "tls_cacert_subject_common_name" {
description = "The self-generated CA cert subject common name used to sign all cluster certs. The cluster certs are used to secure and validate inter-cluster requests. The subject common name of this CA cert must be different from the subject common name for the Kubernetes' certificates. Otherwise, Kubernetes will fail, complaining that it's been assigned a self-signed certificate."
}
variable "tls_cacert_subject_organization" {
description = "The self-generated CA cert subject organization name."
}
variable "tls_etcd_cert_subject_common_name" {
description = "The etcd TLS cert subject organization name."
default = "system:etcd"
}
variable "tls_etcd_cert_subject_organization" {
description = "The etcd TLS cert subject organization name."
default = "system:etcd"
}
variable "tls_coredns_cert_subject_common_name" {
description = "The CoreDNS TLS cert subject organization name."
default = "system:serviceaccount:kube-system:coredns"
}
variable "tls_coredns_cert_subject_organization" {
description = "The CoreDNS TLS cert subject organization name."
default = "system:serviceaccounts:kube-system"
}
variable "tls_kube_apiserver_cert_subject_common_name" {
description = "The kubernetes API Server TLS cert subject organization name."
default = "kubernetes"
}
variable "tls_kube_apiserver_cert_subject_organization" {
description = "The kubernetes API Server TLS cert subject organization name."
default = "system:masters"
}
variable "tls_kube_proxy_cert_subject_common_name" {
description = "The kube-proxy TLS cert subject organization name."
default = "system:kube-proxy"
}
variable "tls_kube_proxy_cert_subject_organization" {
description = "The kube-proxy TLS cert subject organization name."
default = "system:node-proxier"
}
variable "tls_workers_cert_subject_common_name" {
description = "The workers' TLS cert subject organization name."
default = "system:node"
}
variable "tls_workers_cert_subject_organization" {
description = "The workers' TLS cert subject organization name."
default = "system:nodes"
}
variable "tls_client_cert_subject_common_name" {
description = "The client's TLS cert subject common name. Kubernetes uses this as the user name for the request. Refer http://kubernetes.io/docs/admin/authentication/#x509-client-certs"
default = "admin"
}
variable "tls_client_cert_subject_organization" {
description = "The client's TLS cert subject organization name. As of Kubernetes 1.4, Kubernetes uses this as the user's group. Refer http://kubernetes.io/docs/admin/authentication/#x509-client-certs"
default = "system:masters"
}
variable "tls_cert_subject_organizational_unit" {
description = "The Kubernetes and etcd clusters' TLS cert subject organizational unit."
}
variable "tls_cert_subject_street_address" {
description = "The Kubernetes and etcd clusters' TLS cert subject street address."
}
variable "tls_cert_subject_locality" {
description = "The Kubernetes and etcd clusters' TLS cert subject locality."
}
variable "tls_cert_subject_province" {
description = "The Kubernetes and etcd clusters' TLS cert subject postal code."
}
variable "tls_cert_subject_postal_code" {
description = "The Kubernetes and etcd clusters' TLS cert subject postal code."
}
variable "tls_cert_subject_country" {
description = "The Kubernetes and etcd clusters' TLS cert subject 2-letter country code."
}
variable "tls_cert_validity_period_hours" {
description = "The validity period in hours of the Kubernetes and etcd clusters' TLS cert."
}
variable "tls_cert_early_renewal_hours" {
description = "The early renewal period in hours of the Kubernetes and etcd clusters' TLS cert. Set this variable to a time period that is earlier than the cert validity to force Terraform to generate a new cert before the existing one expires. "
}
variable "k8s_home" {
default = "/opt/k8s"
}
variable "k8s_bin_home" {
default = "/opt/k8s/bin"
}
variable "k8s_lib_home" {
default = "/opt/k8s/lib"
}
variable "k8s_lib_kubelet_home" {
default = "/opt/k8s/lib/kubelet"
}
variable "k8s_lib_kube_proxy_home" {
default = "/opt/k8s/lib/kube-proxy"
}
variable "k8s_workers_count" {
default = 3
}
variable "k8s_cni_home" {
default = "/opt/cni/bin"
}
variable "k8s_cni_version" {
default = "v0.6.0"
}
variable "flannel_version" {
default = "v0.9.0"
}
variable "flannel_run" {
default = "/run/kube-flannel"
}
variable "flannel_kubeconfig_file" {
default = "/run/kube-flannel/kubeconfig"
}