Skip to content

Allow patching resource before updating Grafana #2247

@Baarsgaard

Description

@Baarsgaard

Is your feature request related to a problem? Please describe.
A way to somehow patch/update resources before applying the resource to a Grafana instance.

Describe the solution you'd like
Potentially: yq/jq paths or the Kubernetes Downward API as a way to template any field on a resource.

Maybe extending the valuesFrom field to support more options?

Like:

  • Replacing part of the url in a datasource.
  • Editing the title of a folder/dashboard depending on the instance name/namespace.
  • Reference values in ConfigMaps/Secrets from the target instance namespace.

Describe alternatives you've considered
Managing multiple copies of the same CRs with different instanceSelector values.

Existing solutions
Generating resources with Grafana Tanka, kubecfg, Terraform, or other tools. But they often lack the information available in Kubernetes.

Similar issues and discussions:

Metadata

Metadata

Assignees

No one assigned

    Labels

    triage/acceptedIndicates an issue or PR is ready to be actively worked on.

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions