Files

79 lines
2.5 KiB
YAML
Raw Permalink Normal View History

2026-01-02 13:52:08 +02:00
services:
2026-01-30 03:15:10 +01:00
openclaw-gateway:
image: ${OPENCLAW_IMAGE:-openclaw:local}
2026-01-02 13:52:08 +02:00
environment:
HOME: /home/node
TERM: xterm-256color
OPENCLAW_GATEWAY_TOKEN: ${OPENCLAW_GATEWAY_TOKEN:-}
OPENCLAW_ALLOW_INSECURE_PRIVATE_WS: ${OPENCLAW_ALLOW_INSECURE_PRIVATE_WS:-}
CLAUDE_AI_SESSION_KEY: ${CLAUDE_AI_SESSION_KEY:-}
CLAUDE_WEB_SESSION_KEY: ${CLAUDE_WEB_SESSION_KEY:-}
CLAUDE_WEB_COOKIE: ${CLAUDE_WEB_COOKIE:-}
TZ: ${OPENCLAW_TZ:-UTC}
2026-01-02 13:52:08 +02:00
volumes:
2026-01-30 03:15:10 +01:00
- ${OPENCLAW_CONFIG_DIR}:/home/node/.openclaw
- ${OPENCLAW_WORKSPACE_DIR}:/home/node/.openclaw/workspace
## Uncomment the lines below to enable sandbox isolation
## (agents.defaults.sandbox). Requires Docker CLI in the image
## (build with --build-arg OPENCLAW_INSTALL_DOCKER_CLI=1) or use
2026-03-19 13:40:10 -07:00
## scripts/docker/setup.sh with OPENCLAW_SANDBOX=1 for automated setup.
## Set DOCKER_GID to the host's docker group GID (run: stat -c '%g' /var/run/docker.sock).
# - /var/run/docker.sock:/var/run/docker.sock
# group_add:
# - "${DOCKER_GID:-999}"
2026-01-02 13:52:08 +02:00
ports:
2026-01-31 21:13:13 +09:00
- "${OPENCLAW_GATEWAY_PORT:-18789}:18789"
- "${OPENCLAW_BRIDGE_PORT:-18790}:18790"
2026-01-02 13:52:08 +02:00
init: true
restart: unless-stopped
command:
[
2026-01-31 21:13:13 +09:00
"node",
"dist/index.js",
2026-01-31 10:54:41 +00:00
"gateway",
2026-01-31 21:13:13 +09:00
"--bind",
"${OPENCLAW_GATEWAY_BIND:-lan}",
"--port",
2026-02-01 18:51:44 +00:00
"18789",
2026-01-02 13:52:08 +02:00
]
healthcheck:
test:
[
"CMD",
"node",
"-e",
"fetch('http://127.0.0.1:18789/healthz').then((r)=>process.exit(r.ok?0:1)).catch(()=>process.exit(1))",
]
interval: 30s
timeout: 5s
retries: 5
start_period: 20s
2026-01-02 13:52:08 +02:00
2026-01-30 03:15:10 +01:00
openclaw-cli:
image: ${OPENCLAW_IMAGE:-openclaw:local}
network_mode: "service:openclaw-gateway"
cap_drop:
- NET_RAW
- NET_ADMIN
security_opt:
- no-new-privileges:true
2026-01-02 13:52:08 +02:00
environment:
HOME: /home/node
TERM: xterm-256color
OPENCLAW_GATEWAY_TOKEN: ${OPENCLAW_GATEWAY_TOKEN:-}
OPENCLAW_ALLOW_INSECURE_PRIVATE_WS: ${OPENCLAW_ALLOW_INSECURE_PRIVATE_WS:-}
2026-01-02 13:52:08 +02:00
BROWSER: echo
CLAUDE_AI_SESSION_KEY: ${CLAUDE_AI_SESSION_KEY:-}
CLAUDE_WEB_SESSION_KEY: ${CLAUDE_WEB_SESSION_KEY:-}
CLAUDE_WEB_COOKIE: ${CLAUDE_WEB_COOKIE:-}
TZ: ${OPENCLAW_TZ:-UTC}
2026-01-02 13:52:08 +02:00
volumes:
2026-01-30 03:15:10 +01:00
- ${OPENCLAW_CONFIG_DIR}:/home/node/.openclaw
- ${OPENCLAW_WORKSPACE_DIR}:/home/node/.openclaw/workspace
2026-01-02 13:52:08 +02:00
stdin_open: true
tty: true
init: true
2026-01-31 21:13:13 +09:00
entrypoint: ["node", "dist/index.js"]
depends_on:
- openclaw-gateway