fix: feat: integrate supervisor into edge container (#344)
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
9c199cdd6f
commit
13a35f8355
4 changed files with 35 additions and 0 deletions
|
|
@ -56,6 +56,30 @@ services:
|
||||||
env_file:
|
env_file:
|
||||||
- .env
|
- .env
|
||||||
|
|
||||||
|
edge:
|
||||||
|
build:
|
||||||
|
context: docker/edge
|
||||||
|
dockerfile: Dockerfile
|
||||||
|
image: disinto/edge:latest
|
||||||
|
container_name: disinto-edge
|
||||||
|
volumes:
|
||||||
|
- /var/run/docker.sock:/var/run/docker.sock
|
||||||
|
- /home/johba/.local/share/claude/versions/2.1.84:/usr/local/bin/claude:ro
|
||||||
|
- ${HOME}/.claude.json:/root/.claude.json:ro
|
||||||
|
- ${HOME}/.claude:/root/.claude:ro
|
||||||
|
- disinto-logs:/opt/disinto-logs
|
||||||
|
environment:
|
||||||
|
- FORGE_SUPERVISOR_TOKEN=${FORGE_SUPERVISOR_TOKEN:-}
|
||||||
|
- ANTHROPIC_API_KEY=${ANTHROPIC_API_KEY:-}
|
||||||
|
- CLAUDE_MODEL=claude-sonnet-4-6
|
||||||
|
- FORGE_TOKEN=${FORGE_TOKEN:-}
|
||||||
|
- FORGE_URL=http://forgejo:3000
|
||||||
|
ports:
|
||||||
|
- "80:80"
|
||||||
|
- "443:443"
|
||||||
|
depends_on:
|
||||||
|
- forgejo
|
||||||
|
|
||||||
forgejo:
|
forgejo:
|
||||||
image: codeberg.org/forgejo/forgejo:1
|
image: codeberg.org/forgejo/forgejo:1
|
||||||
container_name: disinto-forgejo
|
container_name: disinto-forgejo
|
||||||
|
|
@ -69,3 +93,6 @@ services:
|
||||||
- FORGEJO__service__REQUIRE_SIGNIN_VIEW=true
|
- FORGEJO__service__REQUIRE_SIGNIN_VIEW=true
|
||||||
ports:
|
ports:
|
||||||
- "3000:3000"
|
- "3000:3000"
|
||||||
|
|
||||||
|
volumes:
|
||||||
|
disinto-logs:
|
||||||
|
|
|
||||||
|
|
@ -15,5 +15,11 @@ fi
|
||||||
# Start dispatcher in background
|
# Start dispatcher in background
|
||||||
bash /opt/disinto/docker/edge/dispatcher.sh &
|
bash /opt/disinto/docker/edge/dispatcher.sh &
|
||||||
|
|
||||||
|
# Start supervisor loop in background
|
||||||
|
while true; do
|
||||||
|
bash /opt/disinto/supervisor/supervisor-run.sh /opt/disinto/projects/disinto.toml 2>&1 | tee -a /opt/disinto-logs/supervisor.log || true
|
||||||
|
sleep 1200 # 20 minutes
|
||||||
|
done &
|
||||||
|
|
||||||
# Caddy as main process
|
# Caddy as main process
|
||||||
exec caddy run --config /etc/caddy/Caddyfile --adapter caddyfile
|
exec caddy run --config /etc/caddy/Caddyfile --adapter caddyfile
|
||||||
|
|
|
||||||
2
state/.gitignore
vendored
2
state/.gitignore
vendored
|
|
@ -1,2 +1,4 @@
|
||||||
# Active-state files are runtime state, not committed
|
# Active-state files are runtime state, not committed
|
||||||
.*-active
|
.*-active
|
||||||
|
# Supervisor is always active in the edge container — committed guard file
|
||||||
|
!.supervisor-active
|
||||||
|
|
|
||||||
0
state/.supervisor-active
Normal file
0
state/.supervisor-active
Normal file
Loading…
Add table
Add a link
Reference in a new issue