Skip to content

Commit

Permalink
Fixed syntax for "and" conditions (#2869)
Browse files Browse the repository at this point in the history
Fixes a deployment error.

```
<(.Values.monitor.create) and (.Values.monitor.grafana.create)>: can't give argument to non-function .Values.monitor.create
```

We have confirmed that both helm2[1] and helm3[2] work.

[1]: https://v2.helm.sh/docs/chart_template_guide/#operators-are-functions
[2]: https://helm.sh/docs/chart_template_guide/function_list/#and

Co-authored-by: DanielZhangQD <36026334+DanielZhangQD@users.noreply.github.com>
Co-authored-by: Yecheng Fu <fuyecheng@pingcap.com>
  • Loading branch information
3 people authored Jul 7, 2020
1 parent 398dbbb commit 863fb80
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion charts/tidb-cluster/templates/monitor-secret.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{{- if (.Values.monitor.create) and (.Values.monitor.grafana.create) }}
{{- if and .Values.monitor.create .Values.monitor.grafana.create }}
apiVersion: v1
kind: Secret
metadata:
Expand Down

0 comments on commit 863fb80

Please sign in to comment.