Skip to content

Conversation

@RedSunEmpire
Copy link
Contributor

@RedSunEmpire RedSunEmpire commented Oct 7, 2025

Hello,

There are cases where Prometheus watches which serviceMonitors to scrape based on custom labels, it will be useful to have that option in the helm-chart.

This is how the 'serviceMonitor' would look like with custom labels defined in values.yaml:

serviceMonitor:
  enabled: false
  interval: 60s
  scrapeTimeout: 20s
  labels:
    prom-scrape: true

There are cases where Prometheus watches which serviceMonitors to scrape based on custom labels, it will be useful to have that option in the chart.
@till
Copy link
Contributor

till commented Oct 7, 2025

Is an empty value in yaml also false? Could you add an empty default in the values file as well?

@RedSunEmpire
Copy link
Contributor Author

Yes, an empty value in values.yaml is considered 'false' and no custom labels will be added if it is not defined.

I have added a default empty 'labels' key to the serviceMonitor resource in values.yaml, let me know if anything else needs to be changed.

@till till merged commit 9a3b8e5 into Luzilla:main Oct 7, 2025
9 of 10 checks passed
@till
Copy link
Contributor

till commented Oct 7, 2025

@RedSunEmpire Thank you, will try to roll a release this week to update the helm chart.

@RedSunEmpire
Copy link
Contributor Author

Thank you as well for the quick responses and merge.

@till
Copy link
Contributor

till commented Oct 9, 2025

@RedSunEmpire I've updated the chart. Had to manually push it. And for some reason, I made 0.2.3, instead of 0.2.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants