galera-operator
galera-operator copied to clipboard
Passing parameters to the docker prom/mysql-exporter
According to the documentation of the prom/mysqld-exporter docker, it is possible to pass parameters to the mysqld-exporter program to be able to collect or delete certain metrics. For this, the collect flags must be passed under the args tag
Example deployment file
apiVersion: apps/v1
kind: Deployment
metadata:
name: mysqld-exporter
labels:
app: mysqld-exporter
spec:
selector:
matchLabels:
app: mysqld-exporter
replicas: 1
template:
metadata:
annotations:
prometheus.io/scrape: "true"
prometheus.io/port: "9104"
labels:
app: mysqld-exporter
spec:
containers:
- name: mysqld-exporter
image: prom/mysqld-exporter
args: [--collect.auto_increment.columns, --no-collect.slave_status]
env:
- name: DATA_SOURCE_NAME
value: root:password@(mysql:3306)/
Currently, the Galera operator does not interpret the args tag at the metric container
So you want to add an "args" field instead of designing your exporter with the right argument ? It can be implemented.