모니터링(Grafana, Prometheus)/Prometheus

Prometheus Helm 설치

babbeolicoding 2023. 5. 1. 22:02

Helm으로 간단하게 Prometheus 설치가 가능하다.

 

1. Helm 설치

#Helm 설치
sudo snap install helm --classic
helm version
#저장소 등록
helm repo add prometheus-community https://prometheus-community.github.io/helm-charts
#저장소 복사
git clone https://github.com/prometheus-community/helm-charts

 

2. Prometheus 설치

#해당 파일 경로로 이동
cd helm-charts/charts/prometheus
#namespace 생성
kubectl create namespace prometheus
#helm으로 prometheus 설치
helm install prometheus prometheus-community/prometheus -f values.yaml --namespace prometheus

 

3. Prometheus 설치 확인

#pod 확인
kubectl get pod -n prometheus
#deployment 확인
kubectl get deployment -n prometheus
#pv, pvc 확인
kubectl get pv
kubectl get pvc -n prometheus

 

Prometheus 삭제

#helm으로 prometheus 삭제
helm uninstall prometheus --namespace monitoring