Grafana Mimir image with healthcheck
This repo provides a thin Docker image on top of grafana/mimir that adds the so desired Docker healthcheck. As the Grafana Mimir team decided to target Kubernetes-only deployments (see issue grafana/mimir#9034) this image exists for Docker/Podman users.
- Port:
9009 - Interval:
3s - Timeout:
2s - Retries:
10
Mimir is expected to listen on port 9009 inside the container (its preferred port). If you change the internal port, you must override the healthcheck command. Use --health-cmd flag if using Docker CLI, healthcheck directive if using Docker Compose.
Pull the image:
docker pull zguydev/mimir-healthcheck:latestRun:
docker run --rm \
-p 9009:9009 \
-v ./config.yaml:/etc/mimir/config.yaml:ro \
zguydev/mimir-healthcheck:latest \
-config.file=/etc/mimir/config.yamlservices:
mimir:
image: zguydev/mimir-healthcheck:latest
command: ["-config.file=/etc/mimir/config.yaml"]
volumes:
- ./config.yaml:/etc/mimir/config.yaml
ports:
- "9009:9009"
healthcheck:
test: ["CMD", "/healthcheck", "--port", "9009"] # Override the port argument if you changed it in Mimir config
restart: unless-stoppedUse this method if you want to use base image versions that aren't provided by the zguydev/mimir-healthcheck tags (versions prior 2.15.0 need to be built manually).
git clone https://github.com/zguydev/mimir-healthcheck
cd mimir-healthcheck
TAG='2.17.0' # Tag to use
docker build \
--build-arg MIMIR_IMAGE_TAG=$TAG \
-t mimir-healthcheck:$TAG .zguydev/mimir-healthcheck mirrors upstream Mimir semver tags: stable releases (like 2.17.0) and prereleases (like 2.17.0-rc.0). Only stable releases of the latest version receive the latest tag.
Images are published to GitHub Container Registry and mirrored to Docker Hub.
This image builds a custom healthcheck binary and puts it inside container; it does not change how you configure or run Mimir.
MIT - see LICENSE