Monitoring and observability with Docker
Know what your server is doing: metrics with Prometheus, Node Exporter and cAdvisor; dashboards with Grafana; real-time monitoring with Netdata and Glances; centralized logs with Loki and live logs with Dozzle; and a lightweight monitor with Beszel.
-
How to Install Prometheus with Docker
Prometheus is the most widely adopted open-source monitoring and alerting system for self-hosted infrastructure, and with Docker you bring it up with a single docker-compose.yml and a prometheus.yml. It collects metrics using a pull model, stores them in its time-series database and exposes them on port 9090, ready to query with PromQL and visualise in Grafana.
-
Host and Container Metrics with Node Exporter and cAdvisor
Node Exporter and cAdvisor are the two exporters that feed Prometheus: the first collects host metrics (CPU, RAM, disk and network) on port 9100, and the second collects per-container metrics on port 8080. This guide brings both up with a single docker-compose.yml, connects them to Prometheus and explains which metrics to watch.
-
How to Install Grafana with Docker
Grafana is the most widely used open-source platform for building dashboards and visualising metrics, and with Docker you bring it up with a single docker-compose.yml. It listens on port 3000, stores its data in /var/lib/grafana and connects to Prometheus, Loki or InfluxDB as data sources. Here you install it, provision it and publish it with Traefik.
-
How to Centralize Logs with Grafana Loki in Docker
Grafana Loki is an open-source log aggregation system that indexes only labels and keeps the content compressed, which makes storage ten to a hundred times cheaper than Elasticsearch. With Docker you bring it up with a single docker-compose.yml, ship your logs with the Docker driver or Grafana Alloy and query them with LogQL in Grafana on port 3100.
-
How to View Container Logs with Dozzle
Dozzle is a real-time log viewer for containers, written in Go: it stores nothing, it reads the logs straight from the Docker socket and streams them to your browser. With Docker you bring it up with a single docker-compose.yml, it listens on port 8080 and shows the live logs of every one of your containers.
-
How to Install Netdata with Docker
Netdata is a real-time monitoring system that, with Docker, shows hundreds of per-second metrics from your server and its containers with almost no configuration. It comes up with a single docker-compose.yml that mounts the host system paths, exposes a full dashboard on port 19999 and automatically detects every service you run.
-
How to Monitor Your Server with Glances in Docker
Glances is a real-time system monitor written in Python that, in web server mode, shows CPU, memory, disk, network and containers from the browser on port 61208. With Docker you bring it up with a single docker-compose.yml, mounting the Docker socket, and it also exposes a REST API at /api/4 to automate things.
-
How to Install Beszel with Docker
Beszel is a lightweight server monitoring platform built on PocketBase that splits into two pieces: a hub with a web dashboard on port 8090 and an agent that runs on each watched machine and listens on 45876. This guide brings both up with Docker Compose, pairs them and sets up alerts.