3d ago
Frog improvements
What was built?
1. Local RAM state logger —/root/memlog.sh (Debian VPS)
A simple bash script, run via cron every 15 minutes on the Debian VPS. On each run it appends to /root/memlog.txt:
a timestamp,
the full output of free -m,
docker stats --no-stream (per-container RAM usage: LinkStack, WriteFreely),
a list of the top 15 RAM-consuming processes (ps aux --sort=-%mem).
Why: this is the only historical data source that should survive even a critical RAM lockup — unlike heavier tools (e.g. Uptime Kuma), the logger itself is light enough that it should still manage to run just before a full system freeze, giving us one last glimpse of what was happening right before an outage.
Verified: service cron status confirmed the cron service is active and configured to start automatically after a server reboot (enabled), so the logger will survive even another emergency restart without needing manual intervention.
2. Better Stack — uptime monitoring
Chosen as the external, free monitoring service (an equivalent/competitor to UptimeRobot, with a broader ecosystem: incident management, heartbeats, logs). Slack integration was configured (bartlabsdev.slack.com, errors channel), with settings: single channel (not thread-based/channel-based, since those are paid features), own team only (no escalation needed, since this is a one-person project).
Two uptime monitors (checked every 3 minutes, Europe region only — a deliberate simplification, see section 4 on trade-offs):
bartlabs.dev (LinkStack) — created automatically during onboarding.
blog.bartlabs.dev (WriteFreely) — created manually, with the maintenance window disabled (all weekdays unchecked, so the monitor is never silenced).
Why: this gives an independent, external source of truth about site availability — if the origin server stops responding (as it did this morning), you get a Slack alert instead of finding out by chance when trying to visit the site.
Completed