Skip to content

Commit 0997d49

Browse files
kpshjkDennis Ploeger
andcommitted
Apply suggestions from code review
Co-authored-by: Dennis Ploeger <[email protected]>
1 parent f25ad9a commit 0997d49

File tree

3 files changed

+39
-15
lines changed

3 files changed

+39
-15
lines changed

README.md

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ Default: `""`
8484

8585
### set-list
8686

87-
Description: A list of settings to apply to on the helm chart using its parameter 'set { }'. Example:
87+
Description: A list of additional settings to apply to the helm chart using the terraform `set{}` parameter. Example:
8888
```
8989
set-list = [
9090
{
@@ -95,13 +95,21 @@ Description: A list of settings to apply to on the helm chart using its paramete
9595
]
9696
```
9797

98-
Type: `list(object({name = string, value = string, type = string}))`
98+
Type:
99+
100+
```hcl
101+
list(object({
102+
name = string,
103+
value = string,
104+
type = string,
105+
}))
106+
```
99107

100108
Default: `[]`
101109

102110
### values
103111

104-
Description: A list of values to apply on the helm chart using its parameter 'values = [...]'. Example:
112+
Description: A list of additional values to apply to the helm chart using the 'values = [...]' parameter. Example:
105113
```
106114
values = [
107115
"<yaml>",
@@ -112,8 +120,6 @@ Type: `list(string)`
112120

113121
Default: `[]`
114122

115-
###
116-
117123
## Outputs
118124

119125
No outputs.

main.tf

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,11 +18,11 @@ resource "helm_release" "cert-manager" {
1818
}
1919

2020
dynamic "set" {
21-
for_each = var.set-list
21+
for_each = var.set-list
2222
content {
23-
name = lookup(set.value, "name", null)
23+
name = lookup(set.value, "name", null)
2424
value = lookup(set.value, "value", null)
25-
type = lookup(set.value, "type", null)
25+
type = lookup(set.value, "type", null)
2626
}
2727
}
2828

vars.tf

Lines changed: 25 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -24,16 +24,34 @@ variable "cluster-issuers-yaml" {
2424

2525
variable "set-list" {
2626
type = list(object({
27-
name = string,
27+
name = string,
2828
value = string,
29-
type = string,
29+
type = string,
3030
}))
31-
default = []
32-
description = "A list of settings to apply to on the helm chart using its parameter 'set { }' "
31+
default = []
32+
description = <<EOT
33+
A list of additional settings to apply to the helm chart using the terraform `set{}` parameter. Example:
34+
```
35+
set-list = [
36+
{
37+
"name" = "prometheus.enabled",
38+
"value" = "false",
39+
"type" = "auto"
40+
},
41+
]
42+
```
43+
EOT
3344
}
3445

3546
variable "values" {
36-
type = list(string)
37-
default = []
38-
description = "A list of values to apply on the helm chart using its parameter 'values = [...]' "
47+
type = list(string)
48+
default = []
49+
description = <<EOT
50+
A list of additional values to apply to the helm chart using the 'values = [...]' parameter. Example:
51+
```
52+
values = [
53+
"<yaml>",
54+
]
55+
```
56+
EOT
3957
}

0 commit comments

Comments
 (0)