From 1d43170cfe5d88d2a25092957d6ba774e2d0949f Mon Sep 17 00:00:00 2001 From: "david.truong.hes" <david.truong@master.hes-so.ch> Date: Thu, 17 Apr 2025 19:06:30 +0200 Subject: [PATCH] Docs, rook-ceph: Ajout des commandes pour activer le monitoring dans Prometheus --- rook-ceph/configs/cluster/cluster.yaml | 2 ++ rook-ceph/setup_rook_ceph.txt | 21 +++++++++++++++++++++ 2 files changed, 23 insertions(+) diff --git a/rook-ceph/configs/cluster/cluster.yaml b/rook-ceph/configs/cluster/cluster.yaml index f713beb..f382c5f 100644 --- a/rook-ceph/configs/cluster/cluster.yaml +++ b/rook-ceph/configs/cluster/cluster.yaml @@ -12,6 +12,8 @@ spec: dashboard: enabled: true ssl: true + prometheusEndpoint: http://10.136.126.180:30900 + prometheusEndpointSSLVerify: true mon: count: 3 diff --git a/rook-ceph/setup_rook_ceph.txt b/rook-ceph/setup_rook_ceph.txt index 7fdef07..97d57ba 100644 --- a/rook-ceph/setup_rook_ceph.txt +++ b/rook-ceph/setup_rook_ceph.txt @@ -15,6 +15,27 @@ kubectl -n rook-ceph exec -it deploy/rook-ceph-tools -- bash helm get manifest rook-ceph -n rook-ceph +Monitoring - Prometheus + +apt-get install git +git clone --single-branch --branch v1.17.0 https://github.com/rook/rook.git +cd rook/deploy/examples/monitoring +kubectl apply -f service-monitor.yaml +kubectl apply -f exporter-service-monitor.yaml +kubectl apply -f prometheus.yaml +kubectl apply -f prometheus-service.yaml +kubectl -n rook-ceph get pod prometheus-rook-prometheus-0 +echo "http://$(kubectl -n rook-ceph -o jsonpath={.status.hostIP} get pod prometheus-rook-prometheus-0):30900" + +Editer yaml CRD cluster avec : + +spec: + dashboard: + prometheusEndpoint: http://192.168.61.204:30900 + prometheusEndpointSSLVerify: true + +echo "http://$(kubectl -n rook-ceph -o jsonpath={.status.hostIP} get pod prometheus-rook-prometheus-0):30900" + Dashboard kubectl -n rook-ceph get secret rook-ceph-dashboard-password -o jsonpath="{.data.password}" | base64 -d && echo -- GitLab