mirror of
https://github.com/windmill-labs/windmill.git
synced 2026-10-19 08:03:16 +00:00
feat: add codex agent support to sandbox container
- Install @openai/codex in Dockerfile.sandbox - Pass developer_instructions via -c flag with proper shell escaping - Use --yolo flag for sandbox profile (container is the sandbox) - Mount ~/.codex into container via workmux extra_mounts config Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.6
parent
ab91f78017
commit
0db6cbd10c
@@ -144,6 +144,9 @@ RUN curl -fsSL https://claude.ai/install.sh | bash && \
|
||||
ln -s /usr/local/bin/claude /tmp/.local/bin/claude && \
|
||||
chmod 777 /tmp/.local
|
||||
|
||||
# --- codex agent ---
|
||||
RUN npm i -g @openai/codex
|
||||
|
||||
# Entrypoint that registers the dynamic UID in /etc/passwd so sudo works.
|
||||
# workmux passes --user UID:GID directly, bypassing network-init.sh.
|
||||
RUN cat <<'ENTRY' > /usr/local/bin/entrypoint.sh
|
||||
|
||||
@@ -105,9 +105,11 @@ function buildAgentCmd(profile: Profile, env: Record<string, string>, agent: Age
|
||||
|
||||
if (agent === "codex") {
|
||||
if (profile === "agent-yolo") {
|
||||
return `workmux sandbox agent -- codex --yolo`;
|
||||
const innerEscaped = prompt.replace(/["\\$`]/g, "\\$&");
|
||||
return `workmux sandbox agent -- codex --yolo -c '"developer_instructions=${innerEscaped}"'`;
|
||||
}
|
||||
return "codex";
|
||||
const escapedPrompt = prompt.replace(/'/g, "'\\''");
|
||||
return `codex -c 'developer_instructions=${escapedPrompt}'`;
|
||||
}
|
||||
|
||||
// Claude
|
||||
|
||||
Reference in New Issue
Block a user