github.com/alibaba/sealer@v0.8.6-0.20220430115802-37a2bdaa8173/applications/prometheus-stack/README.md (about) 1 # Overview 2 3 This image collects Kubernetes manifests, [Grafana](http://grafana.com/) dashboards, 4 and [Prometheus rules](https://prometheus.io/docs/prometheus/latest/configuration/recording_rules/) combined with 5 documentation and scripts to provide easy to operate end-to-end Kubernetes cluster monitoring 6 with [Prometheus](https://prometheus.io/) using the Prometheus Operator. 7 8 Components included in this image: 9 10 * The [Prometheus Operator](https://github.com/prometheus-operator/prometheus-operator) 11 * Highly available [Prometheus](https://prometheus.io/) 12 * Highly available [Alertmanager](https://github.com/prometheus/alertmanager) 13 * [Prometheus node-exporter](https://github.com/prometheus/node_exporter) 14 * [Prometheus Adapter for Kubernetes Metrics APIs](https://github.com/DirectXMan12/k8s-prometheus-adapter) 15 * [kube-state-metrics](https://github.com/kubernetes/kube-state-metrics) 16 * [Grafana](https://grafana.com/) 17 18 This stack is meant for cluster monitoring, so it is pre-configured to collect metrics from all Kubernetes components. 19 In addition to that it delivers a default set of dashboards and alerting rules. Many of the useful dashboards and alerts 20 come from the [kubernetes-mixin project](https://github.com/kubernetes-monitoring/kubernetes-mixin), similar to this 21 project it provides composable jsonnet as a library for users to customize to their needs. 22 23 ## About prometheus 24 25 We choose OpenEBS LocalPV as its default persistence storage and deploy it with two replicas resource. many prometheus rules in 26 this image will be loaded when prometheus start. you can check the`Prometheus` and `PrometheusRule` in the cluster for 27 more details. 28 29 ```shell 30 kubectl get Prometheus -n kube-prometheus-stack-system 31 kubectl get PrometheusRule -n kube-prometheus-stack-system 32 ``` 33 34 ## About grafana 35 36 We provide grafana as deployment resource in the cluster and which service type is `ClusterIP`. what's more, we hold 37 many useful grafana dashboard inside which will be applied with the grafana dashboard by default. you can check the 38 `ConfigMap`for more details in the `kube-prometheus-stack-system` namespace. 39 40 ## Access the dashboard 41 42 Prometheus, Grafana, and Alertmanager dashboards can be accessed quickly using kubectl port-forward after running the 43 image via the commands below. 44 45 Examples: 46 47 ```shell 48 kubectl --namespace kube-prometheus-stack-system port-forward service/kube-prometheus-stack-grafana 3000 49 ``` 50 51 Then access via [http://localhost:3000](http://localhost:3000) and use default dashboard access credential : 52 53 ```shell 54 username : admin 55 password : sealer-admin 56 ```