
keep-dashboard
A monochrome live dashboard for a single-box homelab: system, containers, uptime, jobs and activity on square corners, refreshed every second, with a host agent that only accepts a short list of known actions.
keep-dashboard
I moved most of what I run from the cloud to one box at home. An old 8th-gen i5, 6 cores, 32GB of RAM, a 1TB SSD and a 225GB one. I call it the keep. Tailscale gets me in, AdGuard does DNS, Uptime Kuma checks everything and pings my phone through ntfy, and Dokploy deploys the apps.
Once it ran, I wanted one screen that told me the state of it. I tried the existing dashboards and none of them matched my taste: monochrome, boxy, sharp corners. So I wrote my own, on Bun with React and no UI library. It is open source under MIT, and the live one sits behind my tailnet at keep.findmalek.engineer. That link is gated, so you will see a refusal. The point of this page is what is behind it.

An abstract of the overview layout. Real screenshots are further down.
How it grew#
The repo is only a week old, and I will not pretend the history is a long saga. One big first commit, then small pull requests, each one starting from an issue I wrote the same morning.

Six commits, five merged pull requests, and one issue that is still open.
| Date | What landed |
|---|---|
| Oct 11 | Initial release. All six pages, the host agent with its systemd units, SQLite history and the live stream. |
| Oct 13 | Issue 1 opened after an audit: containers publish ports past the firewall. Still open. |
| Oct 15 | Security pull request: the API only answers through the private route, Docker is read through a proxy. CI and the first tests arrive with it. |
| Oct 15 | Range tabs on the system page stop showing stale data and say where history starts. |
| Oct 15 | Uptime bars show each half hour and when it was down when you hover or arrow through them. |
| Oct 17 | Start and stop buttons for apps that sleep, and the tidy job learns to leave them alone. |
The first release already had the agent and the history store. The security work came after, which is the honest order for a weekend project that suddenly held a reboot button.
The pages#
Six of them, all black and white. The only colors are orange and red, and they mean one thing: close to a limit, or at it. Nothing else is allowed to be colored, so when something is, I look.
Overview#

Overview at 1440 wide, fake demo data (overview-page.tsx).
Eight tiles, then panels for music, ad blocking, internet speed and feeds, then space per app against its limit. The design call here was to show answers, not charts. I open this page to find out whether everything is fine, and I should know in one look.
System#

System, with the live tab selected. The other tabs read from SQLite (system-page.tsx).
CPU per core, memory, network per interface, disks, every temperature sensor and every container. Tabs switch between live, 1 hour, 24 hours, 7 days and 30 days. I want every sensor because heat is the first thing I would check on a box that never gets switched off.
Uptime#

Uptime. The address column is blacked out on purpose (uptime-page.tsx).
Every Uptime Kuma check as a 24 hour strip of half hour bars, with response time, uptime percentages and days left on the TLS certificate. I did not build my own checker. Kuma already does it well, so the dashboard reads its metrics (kuma.ts) and draws them my way. Hovering a bar tells you which half hour it was and when it went down, which was the second pull request after the first release (outages.ts).
Apps#

Apps, grouped by project, with example domains (apps-page.tsx).
Every Dokploy project and service, with containers, cpu, memory, domains and the last deploy. Under it sits a log of what the nightly cleanup removed, because a job that deletes things should say what it deleted.
Jobs#

Jobs, with last result, next run and a run now button for each (jobs-page.tsx).
This is the page with buttons, so it is the one I worry about. More on that below.
Activity#
The sixth page (activity-page.tsx) lists the tailnet devices, who is connected right now over SSH, Dokploy or the dashboard, and a 7 day timeline of logins, sudo commands, deploys, cleanups and reboots, folded into sessions. I left its screenshot out of this page, because it shows exactly the kind of detail a page like this should not publish.
One snapshot every second#

Fast things are read each tick, slow things keep their own timer.
One Bun process (server.ts) collects everything and pushes a snapshot to the browser every second over Server-Sent Events. Not everything can be read that fast. CPU and memory can. Asking Dokploy for its projects cannot. So each collector runs on its own timer and writes only its own fields, and the one second tick just merges whatever they last produced. Long-term history, 1 minute averages and peaks for 31 days, goes into SQLite (history-db.ts) and feeds the 1h to 30d tabs.
Every integration is optional. If one is not configured its panel hides or says it is not reachable.
The container cannot run anything on the host#
The dashboard has buttons that can reboot the machine. A web app that can do that is a bad idea if it also holds a shell.

A button drops a file. Only the host agent decides what happens (keep-agent.py).
So the container never runs host commands. A button drops a request file into a shared folder. A systemd path unit notices it (units) and starts a small Python agent on the host. The agent accepts reboot, tidy, run:<known job> and start or stop of a switch I configured. Everything else is refused and logged. It even refuses a reboot if the box booted less than five minutes ago. Requests also need a custom header, so another website cannot trigger them from my browser.
Even if someone owned the web app, the worst they could do is drop a file the agent refuses.

The timers behind the jobs page (host/systemd).
The jobs are plain systemd timers. The nightly cleanup (keep-cleanup.py) runs at 04:30. The weekly tidy (keep-tidy.py) runs Sundays at 05:00: stopped containers, old images, build cache, old journal logs, the apt cache. It never touches Docker volumes or my data. A status timer rewrites the job state every minute so the page stays honest.
What was wrong, and what I did#
The first release was too open. Any container on the same Docker network could call the API and press its buttons, and the Docker socket was mounted into the dashboard. A read-only mount on a socket does not make the API read-only, which surprised me. I fixed it within four days (#5).

Four layers, drawn without any real hostnames or values.
- A private route. The dashboard is reachable through a route that only my devices can use.
- A gate. That route adds a header carrying a long secret, and every API call without it is a 403 (
gate.ts). The check is constant time. The proxy overwrites whatever a client sends, so it cannot be forged from the outside. The health check stays open for uptime. - A proxy for Docker. The socket left the dashboard. A small proxy on its own internal network forwards exactly one request, listing containers. Not inspect, since that would expose other containers' environment.
- The agent. Buttons only ask, as above.
I added CI and a test for the gate in the same change, because there had been no tests at all.
Two lessons were not about security. The 7 day and 30 day graphs looked broken, because history only goes back to the day the dashboard went live. Range tabs now clear old data at once and say where history starts (#6, range-label.ts). And my cleanup once deleted a sleeping game server and its image, because it looked stopped and unused. Now the tidy job skips containers labeled as sleepers (#11), and the jobs page has start and stop buttons for those (#9, jobs.test.ts).
The general lesson I took from the open issue: Docker edits the firewall itself when it publishes a port, so a rule you wrote can be skipped without you noticing. I found that in an audit and the fix is still open. I am not going to describe the details of my own box here.
Power cuts#
Tunisia has frequent power cuts. I set the BIOS so the box powers on by itself when the electricity comes back, and it boots straight into everything it was running. The dashboard is how I check that it actually came back. The uptime in the header tells me whether it rebooted while I was away.
What is still rough#
- No login of its own. It relies on being reachable only through the tailnet, which is fine for me and a bad default for anyone else.
- The published ports issue above is open.
- The agent is about 330 lines of Python with no tests. The server side has a few small ones, for the gate, the Docker proxy (
server.test.ts), jobs, outages and range labels. - No alerts of its own. Uptime Kuma and ntfy do that.
What is next#
The jobs page already has a placeholder for an offsite backup, planned for when new drives arrive. The login is the next thing I would add, since it is the biggest gap in the list above.
Run it#
The README has the steps, the variables and an example compose file. Put it behind your VPN. Source: FindMalek/keep-dashboard.