chromart-gitea-actions/.gitea/workflows/validate-runner.yaml
Martin Dimitrov 62b353d5f6
All checks were successful
Reload Act Runner Stack to clear cache for workflows / diff (push) Successful in 1m23s
Reload Act Runner Stack to clear cache for workflows / deploy-gitainer (push) Successful in 4s
seperate validate runner reload
2026-03-07 11:39:19 -08:00

25 lines
689 B
YAML

name: Validate Runner Reload
on:
workflow_run:
workflows: ["Reload Act Runner Stack to clear cache for workflows"]
types:
- completed
jobs:
validate:
runs-on: ubuntu-22.04
steps:
- name: Wait for Gitainer to restart the runner
run: sleep 30
- name: Check runner age is under 2 minutes
run: |
runner_start=$(docker run --rm --pid=host alpine stat -c %Y /proc/1)
now=$(date +%s)
age_seconds=$((now - runner_start))
echo "Runner age: $age_seconds seconds"
if [ "$age_seconds" -gt 120 ]; then
echo "Validation Failed! Runner did not restart."
exit 1
fi