Skip to content

Feature Request: Support multiple endpoints in ServiceMonitor Helm template #1647

@ramsinghtmdc

Description

@ramsinghtmdc

Hi Capsule maintainers 👋,

I have submitted this PR #1646 to address a limitation in the ServiceMonitor Helm template.

Problem

The current template only supports a single endpoint (.endpoint), which makes it difficult to configure multiple Prometheus scrape endpoints such as:

  • Default /metrics endpoint
  • Liveness/Readiness probes via blackbox-exporter (/healthz and /readyz)
  • Custom health checks with different scrape intervals

Solution

This PR updates the ServiceMonitor template to iterate over .endpoints instead of assuming a single endpoint. The changes include:

  • Support for multiple endpoints in ServiceMonitor
  • Integration with blackbox-exporter probes
  • Backward compatibility with single-endpoint setups

Benefits

  • Users can now define multiple scrape endpoints in values.yaml
  • Blackbox-exporter integration works out-of-the-box
  • Existing single-endpoint configurations remain functional

The PR has been tested with both single and multiple endpoints and renders valid ServiceMonitor CRDs.

Kindly review and consider merging this PR 🙏. This enhancement will allow Capsule users to configure Prometheus monitoring more flexibly and robustly.

Thanks for your time and review!

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions