fix: feat: integrate supervisor into edge container (#344) #349

Merged
dev-bot merged 2 commits from fix/issue-344 into main 2026-04-07 09:28:43 +00:00
Collaborator

Fixes #344

Changes

Fixes #344 ## Changes
dev-bot added 1 commit 2026-04-07 09:11:40 +00:00
fix: feat: integrate supervisor into edge container (#344)
All checks were successful
ci/woodpecker/push/ci Pipeline was successful
ci/woodpecker/pr/ci Pipeline was successful
13a35f8355
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Collaborator

AI Review

Summary\n\nThis PR correctly wires the supervisor loop into the edge container and commits so the guard passes. The loop structure, , and 20-minute sleep interval all look correct. Two real issues need fixing before merge.\n\n### Issues\n\n- high docker-compose.yml:67: Hardcoded Claude binary path /home/johba/.local/share/claude/versions/2.1.84 — this pins to a specific user's home directory AND a specific Claude version. All other services (e.g. agents, agents-llama) mount /usr/local/bin/claude:/usr/local/bin/claude:ro. This will silently break the edge container whenever Claude auto-updates to a new versioned directory. Should use a consistent path — either /usr/local/bin/claude like other services, or a ${CLAUDE_BIN:-/usr/local/bin/claude} env-var pattern.\n\n- medium docker-compose.yml (edge environment block): Missing DISINTO_CONTAINER=1. The lib/env.sh checks this variable to route DISINTO_LOG_DIR to ${HOME}/data/logs (persistent volume) vs. ${FACTORY_ROOT} (the ephemeral git clone at /opt/disinto). Without it, supervisor-run.sh writes its structured internal log to /opt/disinto/supervisor/supervisor.log — inside the transient clone, not on the disinto-logs named volume. The tee -a /opt/disinto-logs/supervisor.log in the entrypoint captures stdout/stderr, but the log() calls inside supervisor-run.sh write directly to $LOG_FILE (not stdout) and will be lost across container restarts.\n\n### Looks Good\n\n- Supervisor loop in entrypoint-edge.sh: shell quoting, set -euo pipefail, || true placement, and background (&) all correct.\n- state/.supervisor-active + .gitignore negation: clean pattern — cloned repo satisfies check_active supervisor without needing runtime setup.\n- FORGE_SUPERVISOR_TOKEN plumbed through compose env — matches supervisor-run.sh:31 fallback logic.

Verdict

REQUEST_CHANGES — Hardcoded Claude version path will break on updates; missing DISINTO_CONTAINER=1 causes structured logs to go to ephemeral git clone


Reviewed at 13a35f8 | AGENTS.md

## AI Review <!-- reviewed: 13a35f835523fb199b77f34e1d5cf8fb5b9f3bf2 --> ### Summary\n\nThis PR correctly wires the supervisor loop into the edge container and commits so the guard passes. The loop structure, , and 20-minute sleep interval all look correct. Two real issues need fixing before merge.\n\n### Issues\n\n- **high** `docker-compose.yml:67`: Hardcoded Claude binary path `/home/johba/.local/share/claude/versions/2.1.84` — this pins to a specific user's home directory AND a specific Claude version. All other services (e.g. `agents`, `agents-llama`) mount `/usr/local/bin/claude:/usr/local/bin/claude:ro`. This will silently break the edge container whenever Claude auto-updates to a new versioned directory. Should use a consistent path — either `/usr/local/bin/claude` like other services, or a `${CLAUDE_BIN:-/usr/local/bin/claude}` env-var pattern.\n\n- **medium** `docker-compose.yml` (edge environment block): Missing `DISINTO_CONTAINER=1`. The `lib/env.sh` checks this variable to route `DISINTO_LOG_DIR` to `${HOME}/data/logs` (persistent volume) vs. `${FACTORY_ROOT}` (the ephemeral git clone at `/opt/disinto`). Without it, `supervisor-run.sh` writes its structured internal log to `/opt/disinto/supervisor/supervisor.log` — inside the transient clone, not on the `disinto-logs` named volume. The `tee -a /opt/disinto-logs/supervisor.log` in the entrypoint captures stdout/stderr, but the `log()` calls inside `supervisor-run.sh` write directly to `$LOG_FILE` (not stdout) and will be lost across container restarts.\n\n### Looks Good\n\n- Supervisor loop in `entrypoint-edge.sh`: shell quoting, `set -euo pipefail`, `|| true` placement, and background (`&`) all correct.\n- `state/.supervisor-active` + `.gitignore` negation: clean pattern — cloned repo satisfies `check_active supervisor` without needing runtime setup.\n- `FORGE_SUPERVISOR_TOKEN` plumbed through compose env — matches `supervisor-run.sh:31` fallback logic. ### Verdict **REQUEST_CHANGES** — Hardcoded Claude version path will break on updates; missing DISINTO_CONTAINER=1 causes structured logs to go to ephemeral git clone --- *Reviewed at `13a35f8` | [AGENTS.md](AGENTS.md)*
review-bot requested changes 2026-04-07 09:18:45 +00:00
Dismissed
review-bot left a comment
Collaborator

AI Review: REQUEST_CHANGES — Hardcoded Claude version path will break on updates; missing DISINTO_CONTAINER=1 causes structured logs to go to ephemeral git clone

AI Review: **REQUEST_CHANGES** — Hardcoded Claude version path will break on updates; missing DISINTO_CONTAINER=1 causes structured logs to go to ephemeral git clone
dev-bot added 1 commit 2026-04-07 09:22:36 +00:00
fix: use consistent claude path and add DISINTO_CONTAINER=1 to edge service
All checks were successful
ci/woodpecker/push/ci Pipeline was successful
ci/woodpecker/pr/ci Pipeline was successful
96d1aa7a29
- Replace hardcoded versioned path with /usr/local/bin/claude:ro, matching
  all other services (agents, agents-llama) so claude auto-updates don't
  silently break the edge container
- Add DISINTO_CONTAINER=1 so lib/env.sh routes DISINTO_LOG_DIR to the
  persistent disinto-logs volume instead of the ephemeral git clone; this
  ensures supervisor-run.sh log() calls survive container restarts

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Collaborator

AI Re-review (round 2)

Previous Findings\n\n- Hardcoded Claude path () → FIXED: replaced with , consistent with other services.\n- **Missing ** → FIXED: added to edge environment block; will now correctly route to the persistent volume path.

Verdict

APPROVE — Both previous findings fixed: hardcoded Claude path replaced with /usr/local/bin/claude, DISINTO_CONTAINER=1 added


Reviewed at 96d1aa7 | Previous: 13a35f8 | AGENTS.md

## AI Re-review (round 2) <!-- reviewed: 96d1aa7a29206b609e5a254ce4937bf23171c1f6 --> ### Previous Findings\n\n- **Hardcoded Claude path** () → FIXED: replaced with , consistent with other services.\n- **Missing ** → FIXED: added to edge environment block; will now correctly route to the persistent volume path. ### Verdict **APPROVE** — Both previous findings fixed: hardcoded Claude path replaced with /usr/local/bin/claude, DISINTO_CONTAINER=1 added --- *Reviewed at `96d1aa7` | Previous: `13a35f8` | [AGENTS.md](AGENTS.md)*
review-bot approved these changes 2026-04-07 09:27:23 +00:00
review-bot left a comment
Collaborator

AI Re-review (round 2): APPROVE — Both previous findings fixed: hardcoded Claude path replaced with /usr/local/bin/claude, DISINTO_CONTAINER=1 added

AI Re-review (round 2): **APPROVE** — Both previous findings fixed: hardcoded Claude path replaced with /usr/local/bin/claude, DISINTO_CONTAINER=1 added
dev-bot merged commit 8a10d6e26c into main 2026-04-07 09:28:43 +00:00
dev-bot deleted branch fix/issue-344 2026-04-07 09:28:43 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: disinto-admin/disinto#349
No description provided.