35 lines
906 B
Markdown
35 lines
906 B
Markdown
# Prometheus Setup
|
|
|
|
- <https://github.com/prometheus-community/helm-charts/tree/main/charts/kube-prometheus-stack>
|
|
- <https://github.com/prometheus-community/helm-charts/blob/main/charts/kube-prometheus-stack/values.yaml>
|
|
|
|
## helm chart
|
|
|
|
```bash
|
|
#add repo
|
|
helm repo add prometheus-community https://prometheus-community.github.io/helm-charts
|
|
```
|
|
|
|
**This helm chart, installs:**
|
|
|
|
- crd
|
|
- Operator
|
|
- kubernetes services monitors
|
|
|
|
```bash
|
|
kubectl get namespace monitoring || kubectl create namespace monitoring
|
|
helm upgrade --install prometheus-stack prometheus-community/kube-prometheus-stack \
|
|
--namespace monitoring \
|
|
--values=./helm/01-only-crd-and-operator.yaml \
|
|
--values=./helm/02-kube-metrics.yaml \
|
|
--values=./helm/03-node-exporter.yaml \
|
|
--values=./helm/04-kubelet.yaml \
|
|
--values=./helm/10-testing-values.yaml
|
|
```
|
|
|
|
## deploy prometheus agent
|
|
|
|
```bash
|
|
kubectl apply -f ./prometheus-agent.yaml
|
|
```
|