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

[Trino] ServiceMonitor additonal options #318

Open
metalshanked opened this issue Mar 21, 2025 · 0 comments
Open

[Trino] ServiceMonitor additonal options #318

metalshanked opened this issue Mar 21, 2025 · 0 comments

Comments

@metalshanked
Copy link

Currently the service monitor section exposes a few options.

Would be great if additional configuration can be allowed such as "port", "basic auth" etc

For example, here is a custom ServiceMonitor config to rewire it to use OpenMetrics from the trino instance.
Unfortunately, this would get overwritten by Trino Helm chart with servicemonitor as "true" in the chart

apiVersion: monitoring.coreos.com/v1
kind: ServiceMonitor
metadata:
  annotations:
    meta.helm.sh/release-name: trino-cluster
    meta.helm.sh/release-namespace: trino
  creationTimestamp: '2025-03-21T14:24:22Z'
  labels:
    app.kubernetes.io/instance: trino-cluster
    app.kubernetes.io/managed-by: Helm
    app.kubernetes.io/name: trino-cluster
    app.kubernetes.io/version: '470'
    helm.sh/chart: trino-1.37.0
    prometheus: kube-prometheus
  name: trino-cluster
  namespace: trino
spec:
  endpoints:
    - basicAuth:
        password:
          key: password
          name: trino-basic-auth
        username:
          key: username
          name: trino-basic-auth
      interval: 30s
      port: http
      relabelings:
        - action: replace
          regex: (.*)
          replacement: mytrinoserverhost:443
          sourceLabels:
            - __address__
          targetLabel: __address__
        - action: replace
          replacement: mytrinoinstance
          targetLabel: instance
        - action: replace
          replacement: trino-coordinator
          targetLabel: job
      scheme: https
      tlsConfig:
        #Set to true only for devtest. Not in prod!
        insecureSkipVerify: true
  namespaceSelector:
    matchNames:
      - trino
  selector:
    matchLabels:
      app.kubernetes.io/component: coordinator
      app.kubernetes.io/instance: trino-cluster
      app.kubernetes.io/name: trino-cluster
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

1 participant