Secure by Design, Built for Speed, Hardened Container Images on a minimal base CleanStart OS.
50K+
Verified PROMETHEUS-MYSQLD-EXPORTER Container Image
A hardened, minimal PROMETHEUS-MYSQLD-EXPORTER container image built from source with verifiable software provenance and an SBOM, designed for secure production deployments.
For additional versions including FIPS support, explore CleanStart Images — secure, hardened container images
Download the container image from the registry
docker pull cleanstart/prometheus-mysqld-exporter:latest
docker pull cleanstart/prometheus-mysqld-exporter:latest-dev
Note: cleanstart/prometheus-mysqld-exporter:latest does not support the standard DATA_SOURCE_NAME environment variable used by the upstream mysqld_exporter — instead it requires a .my.cnf config file mounted into the container and the --config.my-cnf= flag passed as an argument; to resolve, create a Kubernetes ConfigMap containing a [client] section with user, password, host, and port, mount it as a volume, and add --config.my-cnf=/etc/mysql/.my.cnf to the container args.
cat > /tmp/.my.cnf << 'EOF'
[client]
user=exporter
password=exporterpassword
host=mysql-host
port=3306
EOF
Run the container with basic configuration
docker run -it --name prometheus-mysqld-exporter \
-v /tmp/.my.cnf:/etc/mysql/.my.cnf:ro \
cleanstart/prometheus-mysqld-exporter:latest \
--config.my-cnf=/etc/mysql/.my.cnf
Deploy with production security settings
docker run -d --name prometheus-mysqld-exporter-prod \
--security-opt=no-new-privileges \
--user 1000:1000 \
--restart unless-stopped \
-p 9104:9104 \
-v /tmp/.my.cnf:/etc/mysql/.my.cnf:ro \
cleanstart/prometheus-mysqld-exporter:latest \
--config.my-cnf=/etc/mysql/.my.cnf
Volume Mount Mount local directory for persistent data
docker run -v /app:/app \
-v /tmp/.my.cnf:/etc/mysql/.my.cnf:ro \
cleanstart/prometheus-mysqld-exporter:latest \
--config.my-cnf=/etc/mysql/.my.cnf
Port Forwarding Run with custom port mappings
docker run -p 9104:9104 \
-v /tmp/.my.cnf:/etc/mysql/.my.cnf:ro \
cleanstart/prometheus-mysqld-exporter:latest \
--config.my-cnf=/etc/mysql/.my.cnf
With Additional Collectors Enable specific MySQL metric collectors
docker run -d --name prometheus-mysqld-exporter-full \
-p 9104:9104 \
-v /tmp/.my.cnf:/etc/mysql/.my.cnf:ro \
cleanstart/prometheus-mysqld-exporter:latest \
--config.my-cnf=/etc/mysql/.my.cnf \
--collect.global_status \
--collect.global_variables \
--collect.info_schema.innodb_metrics \
--collect.info_schema.tables \
--collect.perf_schema.eventsstatements
Why Use CleanStart Images
Content type
Image
Digest
sha256:71826a293…
Size
33.9 MB
Last updated
about 14 hours ago
docker pull cleanstart/prometheus-mysqld-exporter