chore: add check-gitea-logs-direct workflow
Check New Server Env / check (push) Successful in 2s
Downgrade New Runners to v0.2.6 / downgrade (push) Successful in 1m19s

This commit is contained in:
2026-07-13 20:40:18 +08:00
parent be1f062941
commit c4113cbd8d
@@ -0,0 +1,32 @@
name: Check Gitea Actions Logs (direct)
on:
workflow_dispatch:
jobs:
check-gitea-logs:
runs-on: runtime-builder
steps:
- name: Check Gitea Actions logs
shell: sh
run: |
set -eu
echo "=== 1. Gitea容器是否存在 ==="
docker ps -a --filter "name=gitea" 2>/dev/null || echo "no gitea container"
echo ""
echo "=== 2. Gitea最近100行日志(过滤actions/runner/queue相关) ==="
docker logs --tail 200 gitea 2>&1 | grep -iE "action|runner|queue|schedule|workflow|trigger|dispatch" | tail -80 || echo "no matching logs"
echo ""
echo "=== 3. Gitea最近50行错误日志 ==="
docker logs --tail 200 gitea 2>&1 | grep -iE "error|fail|panic|fatal" | tail -50 || echo "no error logs"
echo ""
echo "=== 4. Actions Runner状态表(数据库查) ==="
docker exec gitea sqlite3 /data/gitea.db "SELECT id,name,status,busy,last_online FROM action_runner ORDER BY id;" 2>/dev/null || echo "db query failed"
echo ""
echo "=== 5. 最近的Run记录 ==="
docker exec gitea sqlite3 /data/gitea.db "SELECT id,index,workflow_id,status,trigger_event,head_branch FROM action_run ORDER BY id DESC LIMIT 20;" 2>/dev/null || echo "db query failed"