yoself
v1.1.1
Published
Podman monitoring & status page using [EviKit](https://evikit.js.org/).
Readme
yoself
Podman monitoring & status page using EviKit.
- [x] Monitor host unless
MONITOR_HOST=false- [x] Uptime
- [x] Load average: 1 minute, 5 minutes, 15 minutes
- [x] CPU usage per core, total time
- [x] Used memory, total memory
- [x] Mounts: path, size, used
- [x] Network: name, total over period, receive rate, transmit rate
- [x] Monitor servers once a minute
- [x] Name and URL from environment variable
SERVER_EXAMPLE=https://example.org - [x] Optionally check response with JMESPath if e.g.
JMESPATH_EXAMPLE="json.status == 'healthy'"- [x] If a check for 200 OK is enough, do not set this variable
- [x] Name and URL from environment variable
- [x] Monitor containers unless
DOCKER_SOCKET=- [x] Name, CPU percentage, used memory, block read/written, network received/sent, pids
- [x] Health status
- [x] Volumes: name, size. Images: repository, tag, size
- [x] List unused, otherwise group with containers
- [x] Period
- [x] 1 hour, minute resolution
- [x] 24 hours, 30-minute resolution
- [x] 7 days, hour resolution
- [x] 31 days, 6-hour resolution
- [x] Export 24h static html once a minute if
STATIC_HTML=/home/user/public_html/yoself.html- [x] Install build from npm without dev dependenices
- [x] Notify
[email protected]on status change- [x] Status metrics: load average, free memory, free disk, container health, server health and milliseconds
- [x] Use
SMTP_HOST,SMTP_PORT,SMTP_USER,SMTP_PASSWORD - [x] Allow
SMTP_IPifSMTP_HOSTresolves incorrectly
- [x] Fetch incident updates every 10 minutes from Mastodon RSS if
INCIDENT=https://example.org/@mastodon.rss
Install
Option 1. compose.yaml
For the main server, the containers on which you want to monitor.
services:
yoself:
image: codeberg.org/nykula/yoself:latest
restart: unless-stopped
network_mode: host
environment:
PORT: 5173
volumes:
- yoself-data:/root/.local/share/yoself-nodejs
- /run/podman/podman.sock:/var/run/docker.sockFor each container without a built-in health check command but with an HTTP API, add to environment: SERVER_CONTAINER: https://container.example.org/path/to/health. Instead of CONTAINER, write the name of your container.
Now do:
systemctl enable --now podman.socket
podman-compose upAnd go to http://localhost:5173. If it works ok, set up an HTTPS reverse proxy and firewall the HTTP port.
If using rootless podman, the path in volumes is instead /run/user/1000/podman/podman.sock for user 1000, and the commands are slightly more complicated:
loginctl enable-linger
systemctl --user enable --now podman.socket
podman-compose upOption 2. npm
For the server that checks if your main server is up.
npm config set prefix ~/.local
mkdir -p ~/public_html
npm i -g yoself
cd ~/.local/lib/node_modules/yoself
cat >>.env <<EOF
MONITOR_HOST=false
SERVER_MAIN=https://yoself.example.org/api
JMESPATH_MAIN="json.status == 'healthy'"
STATIC_HTML="$HOME/public_html/yoself.html"
EOF
npm startNote: backup ~/.local/lib/node_modules/yoself/.env before upgrading with npm up -g yoself, and restore it after upgrade.
Make a systemd user service at ~/.config/systemd/user/yoself.service for automatic restart on reboot and/or crash:
[Unit]
Description=URL monitoring & status page
[Service]
WorkingDirectory=%h/.local/lib/node_modules/yoself
ExecStart=/usr/bin/npm start
Restart=on-failure
[Install]
WantedBy=default.targetThen:
loginctl enable-linger
systemctl --user daemon-reload
systemctl --user enable --now yoselfEmail variables
SMTP_HOST,SMTP_PORT,SMTP_USER,SMTP_PASSWORD- sender[email protected]- whom to notify
That's it, you start getting emails on every tracked status change.
Development
git clone https://codeberg.org/nykula/yoself
cd yoself
cp .env.example .env
npm i
npm run devBuild for production:
npm run build
npm startFormat:
npm run formatLicense
SPDX-License-Identifier: AGPL-3.0-or-later
Copyright (C) 2026 Denys Nykula
This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details.
You should have received a copy of the GNU Affero General Public License along with this program. If not, see https://www.gnu.org/licenses/.
