Coder Social home page Coder Social logo

Comments (9)

dabo-devconsole avatar dabo-devconsole commented on August 18, 2024 1

Yes, the kube-prometheus-stack-operator is running in version v0.71.2 in the cluster.

from helm-charts.

aminrj avatar aminrj commented on August 18, 2024 1

Hi,
I am experiencing the same issue but while using Prometheus community Helm chart:
│ Error: failed to create resource: ServiceMonitor.monitoring.coreos.com "prometheus-exporter" is invalid: spec.endpoints: Required value

The result is that the pod is in a CrashLoopBackOff:
prometheus-exporter-f4dc7988f-dmf2d 0/1 CrashLoopBackOff 4 (25s ago) 117s

Here is the configuration of the Helm chart:

kubescape:

  # Enable prometheus pod annotations,to allow your opensource prometheus (not operator) to scrape metrics
  prometheusAnnotation:
    enabled: true


capabilities:
  # Kubescape integration with Prometheus Community Hlem chart
  prometheusExporter: enable

from helm-charts.

dwertent avatar dwertent commented on August 18, 2024

Do you have the Prometheus operator running in your cluster?

from helm-charts.

dwertent avatar dwertent commented on August 18, 2024

This is unusual, I'm unable to reproduce the problem. It seems to be working fine without any issues.
Perhaps we should consider adding the endpoint here just to be cautious.

from helm-charts.

dabo-devconsole avatar dabo-devconsole commented on August 18, 2024

Yes it pretty much looks the same. I'm also using the Prometheus community helm chart, especially the prometheus-community/kube-prometheus-stack.

from helm-charts.

hyo-shin avatar hyo-shin commented on August 18, 2024

I have also encountered this issue:

Error: failed to create resource: ServiceMonitor.monitoring.coreos.com "prometheus-exporter" is invalid: spec.endpoints: Required value

I agree with @dwertent suggestion that the spec.endpoints might need to be added here.

from helm-charts.

lubgi avatar lubgi commented on August 18, 2024

What's the workaround?

from helm-charts.

dwertent avatar dwertent commented on August 18, 2024

I will look into this today :)

from helm-charts.

l-spork-cc avatar l-spork-cc commented on August 18, 2024

We are experiencing the same problem, we deployed a separate servicemonitor outside of the helm deployment as a workaround. The following ressource definition works for us, depending on how the prometheus instance is configured one might also need to add a label for the prometheus selector (we disabled it completely).

apiVersion: monitoring.coreos.com/v1
kind: ServiceMonitor
metadata:
  labels:
    app: prometheus-exporter
  name: kubescape
  namespace: kubescape
spec:
  endpoints:
    - interval: 30s
      targetPort: 8080
      path: /metrics
  namespaceSelector:
    matchNames:
      - kubescape
  selector:
    matchLabels:
      app: prometheus-exporter

from helm-charts.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.