fix(docker): set PICOCLAW_HOME env var to ensure consistent path
When the container runs as a non-root user (picoclaw UID 1000), os.UserHomeDir() returns /home/picoclaw, causing picoclaw to look for config at /home/picoclaw/.picoclaw instead of /root/.picoclaw where the volume is mounted. Setting PICOCLAW_HOME=/root/.picoclaw ensures picoclaw uses the correct path regardless of which user the container runs as. Fixes #2269 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
2701037efb
commit
e58874b8b1
2 changed files with 9 additions and 0 deletions
|
|
@ -10,6 +10,8 @@ services:
|
|||
container_name: picoclaw-agent-full
|
||||
profiles:
|
||||
- agent
|
||||
environment:
|
||||
- PICOCLAW_HOME=/root/.picoclaw
|
||||
volumes:
|
||||
- ../config/config.json:/root/.picoclaw/config.json:ro
|
||||
- picoclaw-workspace:/root/.picoclaw/workspace
|
||||
|
|
@ -30,6 +32,8 @@ services:
|
|||
restart: unless-stopped
|
||||
profiles:
|
||||
- gateway
|
||||
environment:
|
||||
- PICOCLAW_HOME=/root/.picoclaw
|
||||
volumes:
|
||||
# Configuration file
|
||||
- ../config/config.json:/root/.picoclaw/config.json:ro
|
||||
|
|
|
|||
|
|
@ -11,6 +11,8 @@ services:
|
|||
# Uncomment to access host network; leave commented unless needed.
|
||||
#extra_hosts:
|
||||
# - "host.docker.internal:host-gateway"
|
||||
environment:
|
||||
- PICOCLAW_HOME=/root/.picoclaw
|
||||
volumes:
|
||||
- ./data:/root/.picoclaw
|
||||
entrypoint: ["picoclaw", "agent"]
|
||||
|
|
@ -30,6 +32,8 @@ services:
|
|||
# Uncomment to access host network; leave commented unless needed.
|
||||
#extra_hosts:
|
||||
# - "host.docker.internal:host-gateway"
|
||||
environment:
|
||||
- PICOCLAW_HOME=/root/.picoclaw
|
||||
volumes:
|
||||
- ./data:/root/.picoclaw
|
||||
|
||||
|
|
@ -45,6 +49,7 @@ services:
|
|||
- launcher
|
||||
environment:
|
||||
- PICOCLAW_GATEWAY_HOST=0.0.0.0
|
||||
- PICOCLAW_HOME=/root/.picoclaw
|
||||
ports:
|
||||
- "127.0.0.1:18800:18800"
|
||||
- "127.0.0.1:18790:18790"
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue