- Python 38.1%
- CSS 26.6%
- JavaScript 21.4%
- HTML 13%
- Dockerfile 0.9%
| static | ||
| templates | ||
| .dockerignore | ||
| .gitignore | ||
| app.py | ||
| Dockerfile | ||
| mergerfs-dashboard.service | ||
| README.md | ||
| requirements.txt | ||
mergerfs dashboard
A read-only web dashboard for the health and capacity of a mergerfs pool. It reports:
- mount and mergerfs health
- total, used, and available pool capacity
- utilization percentage
- status and capacity of each branch filesystem
- optional cache-drive capacity cards
- ranked folder-size breakdown
- a JSON status endpoint and health-check endpoint
Run locally
python3 -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt
MERGERFS_MOUNT=/mnt/storage flask --app app run --host 0.0.0.0 --port 8080
Open http://server-ip:8080.
The application is read-only and accepts no filesystem path from the browser. Change the monitored path with the MERGERFS_MOUNT environment variable, then restart it.
Some systems report the mergerfs source as just mergerfs, which hides the branch paths from findmnt. Set MERGERFS_BRANCHES to show reliable per-disk cards:
MERGERFS_MOUNT=/mnt/storage \
MERGERFS_BRANCHES='/mnt/disk*' \
flask --app app run --host 0.0.0.0 --port 8080
The branch setting accepts a glob, a colon-separated list, or a comma-separated list.
Cache drives can be shown separately from the mergerfs pool by setting CACHE_DRIVES:
CACHE_DRIVES='/mnt/ssd,/mnt/ssd2'
Folder sizes are scanned separately with du and cached for five minutes so they do not slow down normal status refreshes. The defaults can be changed with:
MERGERFS_FOLDER_DEPTH=1
MERGERFS_FOLDER_LIMIT=20
MERGERFS_FOLDER_CACHE_SECONDS=300
MERGERFS_FOLDER_SCAN_TIMEOUT=120
Deeper scans can take considerably longer on large pools.
Demo mode
Demo mode supplies sample data when developing on a machine without mergerfs:
MERGERFS_DEMO=true flask --app app run --port 8080
On PowerShell:
$env:MERGERFS_DEMO="true"
flask --app app run --port 8080
API
GET /api/status— full mount, capacity, branch status, and optional cache-drive statusGET /api/folders— cached folder-size breakdownGET /api/folders?refresh=1— force a new folder scanGET /health— HTTP 200 when the configured path is a healthy mergerfs mount; otherwise HTTP 503
systemd installation
sudo useradd --system --home /opt/mergerfs-dashboard --shell /usr/sbin/nologin mergerfs-dashboard
sudo mkdir -p /opt/mergerfs-dashboard
sudo cp -r . /opt/mergerfs-dashboard/
sudo chown -R mergerfs-dashboard:mergerfs-dashboard /opt/mergerfs-dashboard
sudo -u mergerfs-dashboard python3 -m venv /opt/mergerfs-dashboard/.venv
sudo -u mergerfs-dashboard /opt/mergerfs-dashboard/.venv/bin/pip install -r /opt/mergerfs-dashboard/requirements.txt
sudo cp mergerfs-dashboard.service /etc/systemd/system/
sudo systemctl daemon-reload
sudo systemctl enable --now mergerfs-dashboard
Edit MERGERFS_MOUNT and MERGERFS_BRANCHES in the service file for your server, then run:
sudo systemctl daemon-reload
sudo systemctl restart mergerfs-dashboard
For internet-facing access, put it behind a reverse proxy with authentication. The app itself intentionally has no login system.