Skip to content

Commit

Permalink
chart: Add comment about Alertmanager confiration rendering with helm…
Browse files Browse the repository at this point in the history
… template engine

Using the helm template engine with Alertmanager configurations
(Alertmanager.yaml) does not seem to work as expected.
It looks like the helm template engine does not recognise any
new config values since all configuration use cases are not
templated.

We resolve to creating a new secret which will be used to override
the default values making it possible for users to edit the
configuration settings.

Closes: #2262
  • Loading branch information
Ebaneck committed Mar 5, 2020
1 parent dd0a726 commit e29b969
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions charts/prometheus-operator.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,19 @@ alertmanager:
matchLabels:
app.kubernetes.io/name: prometheus-operator-alertmanager

## Passing the below configuration directives through the helm template
## engine leads to no changes.
## So let us create a new secret that overrides/patches
## alertmanager-prometheus-operator-alertmanager secret with new config
## read from a ConfigMap (metalk8s-alertmanager-config)
## This implies we don't have to worry about patching the local charts

# config:
# global: '__var_tojson__(alertmanager.spec.notification.config.global)'
# templates: '__var_tojson__(alertmanager.spec.notification.config.templates)'
# route: '__var_tojson__(alertmanager.spec.notification.config.route)'
# receivers: '__var_tojson__(alertmanager.spec.notification.config.receivers)'
# inhibit_rules: '__var_tojson__(alertmanager.spec.notification.config.inhibit_rules)'

prometheusOperator:
tlsProxy:
Expand Down

0 comments on commit e29b969

Please sign in to comment.