Created
January 16, 2024 06:40
-
-
Save zmx/3468ee11b0802f2ef66b578f1e2801c0 to your computer and use it in GitHub Desktop.
Helm template ignore {{expr}}
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# A viable hack is to let Helm render the template as a raw string. | |
# Note the opening and closing curly bracket with a backtick: | |
# | |
# Origin: https://github.com/helm/helm/issues/2798#issuecomment-470435015 | |
# | |
# Excerpt from a Prometheus Alertmanager yaml | |
receivers: | |
- name: slack-receiver | |
slack_configs: | |
- text: |- | |
{{`{{ range .Alerts }} | |
*Alert:* {{ .Annotations.summary }} | |
{{ end }}`}} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment