forked from lablabs/terraform-aws-eks-cert-manager
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathvalues.tf
39 lines (36 loc) · 931 Bytes
/
values.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
locals {
values = yamlencode({
"installCRDs" : true,
"rbac" : {
"create" : var.k8s_rbac_create
}
"serviceAccount" : {
"create" : var.k8s_service_account_create
"name" : var.k8s_service_account_name
"annotations" : {
"eks.amazonaws.com/role-arn" : local.k8s_irsa_role_create ? aws_iam_role.this[0].arn : ""
}
}
})
cluster_issuers_values = yamlencode({
"ingressShim" : {
"defaultIsuserName" : "default"
"defaultIssuerKind" : "ClusterIssuer"
"defaultIssuerGroup" : "cert-manager.io"
}
})
}
data "utils_deep_merge_yaml" "values" {
count = var.enabled ? 1 : 0
input = compact([
local.values,
var.cluster_issuer_enabled ? local.cluster_issuers_values : "",
var.values
])
}
data "utils_deep_merge_yaml" "default_cluster_issuer_values" {
count = var.enabled ? 1 : 0
input = compact([
var.cluster_issuers_values
])
}