From dfe81a5c20fad8b45f6ca01fd0b59a0331ca2016 Mon Sep 17 00:00:00 2001 From: Hermes Agent service account Date: Sun, 19 Jul 2026 18:17:47 -0500 Subject: [PATCH] minecraft: set prometheus exporter to port 9225, manage config via ConfigMap --- .../applications/minecraft/deployment.yaml | 7 ++++ .../minecraft/prometheus-exporter-config.yaml | 35 +++++++++++++++++++ 2 files changed, 42 insertions(+) create mode 100644 cluster/applications/minecraft/prometheus-exporter-config.yaml diff --git a/cluster/applications/minecraft/deployment.yaml b/cluster/applications/minecraft/deployment.yaml index ae344ec..961a28c 100644 --- a/cluster/applications/minecraft/deployment.yaml +++ b/cluster/applications/minecraft/deployment.yaml @@ -158,6 +158,10 @@ spec: mountPath: /data/plugins/sleep-most/config.yml subPath: config.yml readOnly: true + - name: prometheus-exporter-config + mountPath: /data/plugins/PrometheusExporter/config.yml + subPath: config.yml + readOnly: true resources: requests: cpu: "1" @@ -193,3 +197,6 @@ spec: - name: sleep-most-config configMap: name: sleep-most-config + - name: prometheus-exporter-config + configMap: + name: prometheus-exporter-config diff --git a/cluster/applications/minecraft/prometheus-exporter-config.yaml b/cluster/applications/minecraft/prometheus-exporter-config.yaml new file mode 100644 index 0000000..f249cb2 --- /dev/null +++ b/cluster/applications/minecraft/prometheus-exporter-config.yaml @@ -0,0 +1,35 @@ +--- +# minecraft-prometheus-exporter plugin configuration +# Port set to 9225 to match Service/ServiceMonitor definitions. +# Default is 9940 — must be explicitly set here or the plugin won't be scraped. +# Mounted read-only at /data/plugins/PrometheusExporter/config.yml +apiVersion: v1 +kind: ConfigMap +metadata: + name: prometheus-exporter-config + namespace: minecraft + labels: + app.kubernetes.io/name: minecraft + app.kubernetes.io/component: papermc +data: + config.yml: | + host: localhost + port: 9225 + enable_metrics: + entities_total: true + villagers_total: true + loaded_chunks_total: true + jvm_memory: true + players_online_total: true + players_total: true + whitelisted_players: false + tps: true + world_size: true + jvm_threads: true + jvm_gc: true + tick_duration_median: true + tick_duration_average: true + tick_duration_min: false + tick_duration_max: true + player_online: false + player_statistic: false