Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: contact point overrides #1670

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

theSuess
Copy link
Member

@theSuess theSuess commented Sep 9, 2024

Allows users to override settings using config maps or secrets.

I've intentionally not used the templating logic of data sources as IMHO this will cause more issues downstream, especially with contact point templates.

An example contact point would look like this:

apiVersion: grafana.integreatly.org/v1beta1
kind: GrafanaContactPoint
metadata:
  name: grafanacontactpoint-sample
spec:
  name: grafanacontactpoint-sample
  type: "email"
  instanceSelector:
    matchLabels:
      instance: my-grafana-cloud-stack
  settings:
    addresses: [email protected]
  valuesFrom:
    - targetPath: subject
      valueFrom:
        secretKeyRef:
          name: super-secret-data
          key: secret-subject

which will result in:

apiVersion: 1
contactPoints:
    - orgId: 1
      name: grafanacontactpoint-sample
      receivers:
        - uid: 5628b3a0-8fb1-44a8-a694-46bb8849c484
          type: email
          settings:
            addresses: [email protected]
            subject: <value-from-secret>
          disableResolveMessage: false

Fixes: #1595

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

GrafanaContactPoint doesn't support values from secretkeyref
1 participant