minecraft: set prometheus exporter to port 9225, manage config via ConfigMap
This commit is contained in:
@@ -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
|
||||
|
||||
@@ -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
|
||||
Reference in New Issue
Block a user