check-runner-health
БесплатноБез исполняемых скриптовНе проверенCheck the self-hosted CI runner (load, memory, disk, Docker cleanup) and record a dated report in a PR. Use when doing a periodic runner check, or when its…
от torrust★ 539 звёзд на GitHubОб этом скилле
Check Runner Health
Produce a read-only health snapshot of the self-hosted runner and publish it as a report. Setup and operation of the runner are in docs/self-hosted-runner.md; do not repeat them here.
Rules
- Read-only. Do not stop containers, run prunes, delete files, or restart services while collecting. A fix needs the maintainer's explicit approval and an issue; propose it in the report.
- Do not record the runner's public IP, tokens, or credentials.
- Report only what you measured, and label every cause you did not prove as a hypothesis.
- The SSH key has a passphrase that only the maintainer types. Ask the maintainer to open the connection, then reuse it (below). Never request the passphrase in chat.
1. Open One SSH Connection
The torrust-runner-01 host entry is in the maintainer's ~/.ssh/config. Multiplex it so the
passphrase is typed once:
ssh -o ControlMaster=auto -o ControlPath=/tmp/ssh-runner-%C -o ControlPersist=15m torrust-runner-01 'hostname; uptime; nproc'
S="ssh -o ControlPath=/tmp/ssh-runner-%C torrust-runner-01"
Close it at the end: ssh -O exit -o ControlPath=/tmp/ssh-runner-%C torrust-runner-01.
2. Collect
Send the commands to the runner through a quoted heredoc, so single quotes, $, and parentheses reach
the runner unchanged and nothing needs shell-level escaping. Wrapping a command in $S '...' breaks
every command that contains a single quote, such as the awk ones.
$S bash -s <<'EOF'
df -h /
journalctl -u docker-ci-prune.service --since "3 days ago" -o short-iso | awk '{print substr($1,1,10), $NF}'
EOF
In the table, \| is Markdown escaping for a pipe; write a plain | in the command. Run the commands
marked local on your own machine, not through $S.
| Question | Command |
|---|---|
| Runner registered? | Local: gh api repos/torrust/torrust-tracker/actions/runners -q '.runners[] | [.name, .os, .status, (.busy | tostring), ([.labels[].name] | join(","))] | join(" ")' |
| Service state | systemctl show actions.runner.torrust-torrust-tracker.torrust-runner-01.service -p ActiveState -p ActiveEnterTimestamp -p NRestarts |
| Agent, OS, uptime | /home/runner/actions-runner/bin/Runner.Listener --version; . /etc/os-release; echo $PRETTY_NAME; uname -r; uptime; ls /var/run/reboot-required |
| CPU now | nproc; cat /proc/loadavg; top -b -n1 | head -5; vmstat 1 5 |
| CPU per day | For each sa<DD> in /var/log/sysstat: sar -u -f /var/log/sysstat/sa<DD> and sar -q -f ... (average idle, minimum idle, peak ldavg-5) |
| Memory, swap, OOM | free -h; swapon --show; journalctl _TRANSPORT=kernel --since "30 days ago" | grep -c "Killed process" (not journalctl -k: it implies the current boot only, so after a reboot it hides earlier kills and can print a false zero) |
| Disk | df -h /; df -i /; docker system df; du -xh --max-depth=1 / | sort -rh | head; du -sh /home/runner/.cache/torrust-tracker/* |
| Cache records | docker buildx du | tail -3; docker system df -v | sed -n '/Build cache usage/,$p' (a * after a cache id means in use; count them); ctr -n moby snapshots ls | awk 'NR>1{print $NF}' | sort | uniq -c ($NF, not $3: a parentless snapshot has no PARENT value, so $3 is blank for it and it is not counted under its kind) |
| Held containers | docker ps -a --format '{{.ID}} {{.Image}} {{.Names}} {{.Status}} {{.CreatedAt}}'; docker image ls -a |
| Disk-full evidence | journalctl --since "7 days ago" | grep -ci "no space left" and the date of the first match |
| Cleanup timer | systemctl status docker-ci-prune.timer docker-ci-prune.service --no-pager; systemctl is-failed docker-ci-prune.service (check by name, systemctl --failed lists unrelated units); systemctl show docker.service -p ActiveEnterTimestamp (a recent start means Docker was restarted) |
| Bytes freed per run | journalctl -u docker-ci-prune.service --since "30 days ago" -o short-iso | grep -E 'docker(-ci-prune)?\[[0-9]+\]: Total:' | awk '{print substr($1,1,10), $NF}' |
| CI impact | Local: gh run list --repo torrust/torrust-tracker --workflow container.yaml --limit 15, then gh api repos/torrust/torrust-tracker/actions/runs/<id>/jobs for runner_name, step conclusions, and times |
The pru
Установить check-runner-health в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл check-runner-health?
Check the self-hosted CI runner (load, memory, disk, Docker cleanup) and record a dated report in a PR. Use when doing a periodic runner check, or when its disk fills or jobs queue.
Как установить скилл check-runner-health?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл check-runner-health запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
docx
Use this skill whenever the user wants to create, read, edit, or manipulate Word documents (.docx files) or Word templates (.dotx files). Triggers include…
от AnthropicUse this skill whenever the user wants to do anything with PDF files. This includes reading or extracting text/tables from PDFs, combining or merging multiple…
от Anthropicxlsx
Use this skill any time a spreadsheet file is the primary input or output. This means any task where the user wants to: open, read, edit, or fix an existing…
от Anthropicpptx
Use this skill any time a .pptx or .potx file is involved in any way — as input, output, or both. This includes: creating slide decks, pitch decks, or…
от Anthropic