-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathlocal.tf
27 lines (23 loc) · 1.08 KB
/
local.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
locals {
kubernetes_resources_labels = merge({
"cookielab.io/terraform-module" = "aws-kube-cluster-autoscaler",
k8s-addon = "cluster-autoscaler.addons.k8s.io",
}, var.kubernetes_resources_labels)
kubernetes_deployment_labels_selector = {
"cookielab.io/deployment" = "aws-kube-cluster-autoscaler-tf-module",
}
kubernetes_deployment_labels = merge(local.kubernetes_deployment_labels_selector, local.kubernetes_resources_labels)
kubernetes_deployment_image = "${var.kubernetes_deployment_image_registry}:${var.kubernetes_deployment_image_tag}"
kubernetes_deployment_container_command = concat([
"./cluster-autoscaler",
"--v=4",
"--stderrthreshold=info",
"--cloud-provider=aws",
"--skip-nodes-with-local-storage=${var.skip_nodes_with_local_storage ? "false" : "true"}",
"--expander=${var.expander}",
# "--node-group-auto-discovery=asg:tag=${join(",", var.asg_tags)}",
"--balance-similar-node-groups",
"--skip-nodes-with-system-pods=false",
"--aws-use-static-instance-list=true"
], var.additional_autoscaler_options)
}