Reputation: 303
I am new to Kubernetes. I created a service monitor, I am wondering how can I find the created service monitor.
The service monitor is created successfully.
When I use kubectl get services
, I can't find the created service monitor. Can i get some help?
Thanks!
Upvotes: 3
Views: 3309
Reputation: 15312
ServiceMonitor is a custom resource provided by the Prometheus Operator and it's name inside Kubernetes is servicemonitor
. So you have to list you ServiceMonitors with:
kubectl get servicemonitors
Or you can list the specific ServiceMonitor you created with:
kubectl get servicemonitor servicemonitor-sms-config-services
Upvotes: 3