fix: replace cron with while-true loop and gosu in agents entrypoint #379
Labels
No labels
action
backlog
blocked
bug-report
in-progress
prediction/actioned
prediction/dismissed
prediction/unreviewed
priority
tech-debt
underspecified
vision
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: disinto-admin/disinto#379
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Problem
The agents container uses cron to schedule dev-poll, review-poll, and gardener. Cron doesn't inherit Docker compose env vars — it runs jobs in a minimal environment with only HOME, LOGNAME, PATH, SHELL. This caused: claude not found (PATH missing), wrong FORGE_TOKEN (not in crontab), silent failures for hours.
Fix
Replace cron with a while-true loop (same pattern as entrypoint-llama.sh). Use gosu instead of su to drop privileges — gosu execs directly and preserves the full environment.
The AGENT_ROLES env var (already implemented in #197) controls which scripts run. The loop runs each configured role per iteration.
Add gosu to the Dockerfile:
Replace the cron setup in entrypoint.sh with:
Affected files
Acceptance criteria
Regression checklist
Blocked — issue #379
ci_exhausted2026-04-07T20:56:15Z