Docker implementation of the Prometheus Varnish Exporter
10.0K
Docker implementation of the Prometheus Varnish Exporter
# Build image
docker build -t varnish .
# Run NGINX as backend
docker run -d --name=nginx-alpine nginx:alpine
# Run Varnish
docker run -t -i -p 8080:80 -p 9131:9131 \
-e "OFFLOAD_TO_HOST=nginx-alpine" \
-e "OFFLOAD_TO_PORT=80" \
--link=nginx-alpine \
varnish
# Curl
curl http://localhost:9131/metrics
MIT © Travix International
docker pull travix/varnish-prometheus:latest