List resources created by the Helm chart
Run this to list pods, services, daemonsets, deployments, statefulsets, and replicasets in the current namespace:High-level mapping of resources
- The Pods list should show Prometheus, Alertmanager, Grafana, the operator, kube-state-metrics, and one node-exporter pod per node.
- The Services created by the chart are primarily type
ClusterIP(reachable only inside the cluster by default).
If you need to access Prometheus or Grafana from outside the cluster, you must either:
- Change a service to
LoadBalancer, or - Add an Ingress that routes to the service, or
- Use
kubectl port-forwardas a quick, local option.
Inspecting the Prometheus StatefulSet
To review the Prometheus StatefulSet and see how the Prometheus process and its sidecars are configured:- List StatefulSets:
- Save a describe to a file for easier review:
Where Prometheus config and rules come from
- The Prometheus configuration is generated by the Prometheus Operator and injected into the pod via a Secret mounted at
/etc/prometheus/config. - Alerting and recording rules are rendered into ConfigMaps and mounted under
/etc/prometheus/rules/....
prometheus.yaml):
Inspecting the Prometheus Operator deployment
List deployments in the namespace:- Reconcile Prometheus, Alertmanager, and related resources based on higher-level CRDs.
- Generate the Prometheus YAML configuration (stored in Secrets) and rule ConfigMaps from CRD manifests.
- Manage configuration reloads and restarts (via config-reloader sidecars).
- Provide extensibility points such as
ServiceMonitor,PodMonitor, andPrometheusRuleCRDs for declarative configuration.
Best practices and wrap-up
- Prefer using the Operator CRDs (ServiceMonitor, PodMonitor, PrometheusRule) to add scrape targets and alerting/recording rules.
- Do not edit generated Secrets or ConfigMaps directly; changes will be overwritten by the Operator.
- To access Prometheus or Grafana externally, expose services via
LoadBalancer, set up an Ingress, or usekubectl port-forwardfor quick local access. - Monitor the
prometheusStatefulSet and theprometheus-operatorDeployment for health and restart events.
Links and references
- Prometheus Operator / kube-prometheus documentation: https://github.com/prometheus-operator/kube-prometheus
- Prometheus Operator CRDs and docs: https://prometheus-operator.dev/
- Prometheus project: https://prometheus.io/
- Kubernetes documentation: https://kubernetes.io/docs/
- Helm charts / Artifact Hub: https://artifacthub.io/