From c065174d68b80a16c3e28aebe7805d691756b753 Mon Sep 17 00:00:00 2001 From: Gilles Mouchet Date: Tue, 17 Jun 2025 15:05:18 +0200 Subject: [PATCH] add grafana dashboard 19268 Prometheus All Metrics --- README.md | 2 +- config/prometheus/prometheus.yml | 2 +- manage.sh | 16 +++++++++------- 3 files changed, 11 insertions(+), 9 deletions(-) diff --git a/README.md b/README.md index 55b9a57..16af6e5 100644 --- a/README.md +++ b/README.md @@ -183,7 +183,7 @@ docker exec -it -proxy-1 /bin/bash -c "curl -H \"Accept: a - node exporter container - grafana dashboard - 1860 - Node Exporter Full - - 3662 - Prometheus 2.0 Overview + - 19268 - Prometheus All Metrics - 13502 - MinIO Dashboard - 13639 Logs / APP diff --git a/config/prometheus/prometheus.yml b/config/prometheus/prometheus.yml index a34483a..5276654 100644 --- a/config/prometheus/prometheus.yml +++ b/config/prometheus/prometheus.yml @@ -11,7 +11,7 @@ scrape_configs: - targets: - node-exporter:9100 - job_name: minio-job - bearer_token: eyJhbGciOiJIUzUxMiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJwcm9tZXRoZXVzIiwic3ViIjoibWluaW8iLCJleHAiOjQ5MDM0OTIwNjN9.ailN0Xo5ZXOGDUIe_jrqHpNP2JlQKhi7Ss4XIPIa5M8Hjm7UGJuOKLRnpdysHCYo1cPwlWzMCaGpkfE0KbHmqA + bearer_token: eyJhbGciOiJIUzUxMiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJwcm9tZXRoZXVzIiwic3ViIjoibWluaW8iLCJleHAiOjQ5MDM3NjQ0NTR9.NxAYmMmAy0w0sv0zfP9MvgllPCxokn305qy8cY1Zj6v0peaNnqFYuyqXWcXo-UjAua9ZK-7Gbfa5gCSme1an6g metrics_path: /minio/v2/metrics/cluster scheme: http static_configs: diff --git a/manage.sh b/manage.sh index aa2c130..fac4109 100755 --- a/manage.sh +++ b/manage.sh @@ -100,7 +100,7 @@ function remove_folder { #----------------------------------------------------------------- # copy config file function copy_conf_file { - echo -n "Copy loki config file into ${LOKI_CONF_DIR}/: " + echo -n "Copy loki config file into '${LOKI_CONF_DIR}/': " envsubst < ./config/loki/local-config.yaml.tmpl | \ sudo tee ${LOKI_CONF_DIR}/local-config.yaml > /dev/null rc=$? @@ -111,7 +111,7 @@ function copy_conf_file { exit $rc fi - echo -n "Copy proxy (nginx) config file into ${PRX_NGINX_CONF_DIR}/: " + echo -n "Copy proxy (nginx) config file into '${PRX_NGINX_CONF_DIR}/': " sudo cp ./config/nginx/default.conf ${PRX_NGINX_CONF_DIR}/. > /dev/null 2>&1 rc=$? if [ $rc -eq 0 ]; then @@ -121,7 +121,7 @@ function copy_conf_file { exit $rc fi - echo -n "Copy the Prometheus configuration file into ${PROM_CONF_DIR}/: " + echo -n "Copy the Prometheus configuration file into '${PROM_CONF_DIR}/': " sudo cp ./config/prometheus/prometheus.yml ${PROM_CONF_DIR}/. > /dev/null 2>&1 rc=$? if [ $rc -eq 0 ]; then @@ -131,7 +131,7 @@ function copy_conf_file { exit $rc fi - echo -n "Copy promtail config file into ${PROMTAIL_CONF_DIR}/: " + echo -n "Copy promtail config file into '${PROMTAIL_CONF_DIR}/': " sudo cp ./config/promtail/config.yml ${PROMTAIL_CONF_DIR}/. > /dev/null 2>&1 rc=$? if [ $rc -eq 0 ]; then @@ -469,14 +469,16 @@ EOF fi fi # ---- - db_name="Prometheus 2.0 Overview" + #db_name="Prometheus 2.0 Overview" + db_name="Prometheus All Metrics" echo -n "Import '$db_name' dashboard: " # check if already imported response=$(curl -k -s -u "$GF_ADMIN_USER:$GF_ADMIN_PASS" "$GF_ROOT_URL/api/search?query=") if echo "$response" | grep -iq "\"title\":\"$db_name\""; then echo -e "${VERT}ALREADY IMPORTED${NORMAL}" else - import_gf_dashboard 3662 prometheus + #import_gf_dashboard 3662 prometheus + import_gf_dashboard 19268 prometheus rc1=$? if [ $rc1 -eq 0 ]; then echo -e "${VERT}SUCCESSFULLY IMPORTED${NORMAL}" @@ -487,7 +489,7 @@ EOF fi # ---- db_name="MinIO Dashboard" - echo -n "Import $db_name dashboard: " + echo -n "Import '$db_name' dashboard: " # check if already imported response=$(curl -k -s -u "$GF_ADMIN_USER:$GF_ADMIN_PASS" "$GF_ROOT_URL/api/search?query=") if echo "$response" | grep -iq "\"title\":\"$db_name\""; then