Step-by-step instructions for deploying Nightingale with Docker Compose.
Download
Refer to the Binary Installation chapter to download the Nightingale release package. The package contains Docker Compose-related configuration files. You can also clone the Nightingale source repository directly, where the Docker Compose configuration files are also available.
Start
Whether you download the release package or the source repository, after extracting you will find a docker/compose-bridge directory. Enter this directory and run docker-compose up -d (in China, image downloads may fail — you will need to solve the network access issue yourself).
root@ubuntu-linux-22-04-desktop:/opt/n9e/docker/compose-bridge# docker compose up -d
[+] Running 5/5
✔ Container victoriametrics Started 0.6s
✔ Container redis Started 0.6s
✔ Container mysql Started 0.6s
✔ Container nightingale Started 0.2s
✔ Container categraf Started 0.2s
root@ubuntu-linux-22-04-desktop:/opt/n9e/docker/compose-bridge# docker compose ps
NAME IMAGE COMMAND SERVICE CREATED STATUS PORTS
categraf m.daocloud.io/docker.io/flashcatcloud/categraf:latest "/entrypoint.sh" categraf 2 minutes ago Up 3 seconds
mysql mysql:8 "docker-entrypoint.s…" mysql 2 minutes ago Up 4 seconds 0.0.0.0:3306->3306/tcp, :::3306->3306/tcp, 33060/tcp
nightingale m.daocloud.io/docker.io/flashcatcloud/nightingale:latest "sh -c /app/n9e" nightingale 2 minutes ago Up 3 seconds 0.0.0.0:17000->17000/tcp, :::17000->17000/tcp, 0.0.0.0:20090->20090/tcp, :::20090->20090/tcp
redis redis:6.2 "docker-entrypoint.s…" redis 2 minutes ago Up 4 seconds 0.0.0.0:6379->6379/tcp, :::6379->6379/tcp
victoriametrics victoriametrics/victoria-metrics:v1.79.12 "/victoria-metrics-p…" victoriametrics 2 minutes ago Up 4 seconds 0.0.0.0:8428->8428/tcp, :::8428->8428/tcp
Docker Compose starts multiple containers:
victoriametrics: time-series database, compatible with Prometheus and offering better performanceredis: cache database; Nightingale uses Redis to store JWT tokens and heartbeat metadata for machinesmysql: relational database; Nightingale uses MySQL to store user information, alert rules, dashboards, and other configuration datanightingale: the core Nightingale servicecategraf: monitoring data collector that gathers host metrics such as CPU, memory, and disk
Login
Open http://localhost:17000 in your browser to access the Nightingale UI. The default username is root and the default password is root.2020.
Replace
localhostwith your server’s IP address.
Cluster Mode
In cluster mode, multiple n9e instances must share a common MySQL and Redis, so the default Docker Compose setup is not enough. You need to modify the config.toml file in the etc-nightingale directory to configure unified MySQL and Redis connection information.
Edge Mode
Edge mode requires the n9e-edge process. However, the community does not provide a Docker image for n9e-edge, so the n9e-edge process must still be deployed via the binary method in edge mode. For details on edge mode, see: Edge Mode in Nightingale Architecture.