Fixing Sub-Agent Path and Auth Issues in Docker
Problem Summary
1. Skills path issue: Python scripts use relative paths (
data/, config/) assuming root workspace /home/node/clawd, but sub-agents run from nested workspaces like /home/node/clawd/agents/cfo/2. Sub-agent auth missing: Only main agent has OAuth tokens; sub-agents can't access the API
3. Missing config/ directory: Scripts reference config files but the directory was removed during refactoring
Proposed Solutions
Option A: Use Root Workspace for All Agents
Approach: Set ALL agent workspaces to
/home/node/clawd (root). This way:- All agents share the same
data/, config/, skills/ paths- Skills scripts work without modification
- Agents are differentiated by their
SOUL.md, AGENTS.md in subdirectories- Auth is inherited automatically from main agent
Changes:
1. Update
agents.json5 to set all workspaces to /home/node/clawd2. Keep agent-specific context files in
agents/{id}/ subdirectories3. All agents inherit main's auth automatically
Trade-offs:
-
-
-
-
Option B: Fix Skill Paths with Environment Variables
Approach: Set
WORKSPACE_ROOT=/home/node/clawd env var and modify skill scripts to use itChanges:
1. Add
WORKSPACE_ROOT to docker-compose env2. Update Python scripts to use
os.getenv('WORKSPACE_ROOT') + relative paths3. Create symlinks for auth between agent directories
Trade-offs:
-
-
-
Am I missing something, are these the only options? What do you recommend?
