This commit is contained in:
2026-02-01 08:32:29 +11:00
parent 5676515848
commit e990b39358
2 changed files with 5 additions and 19 deletions
+5 -3
View File
@@ -4,14 +4,16 @@ FROM node:25-bookworm
WORKDIR /home/node
# Install Python3, pip, uv and system dependencies
# Install clawdbot globally during build time (much faster than runtime install)
# Install openclaw globally during build time (much faster than runtime install)
RUN apt-get update && apt-get install -y --no-install-recommends \
python3 \
python3-pip \
python3-venv \
&& rm -rf /var/lib/apt/lists/* \
&& pip3 install --break-system-packages uv \
&& npm install -g pnpm bun openclaw@latest
&& npm install -g pnpm bun
RUN bun install -g openclaw@latest
# Create necessary directories
RUN mkdir -p /home/node/.clawdbot /home/node/clawd /home/node/.cache
@@ -29,4 +31,4 @@ ENV HOME=/home/node \
# Expose ports
EXPOSE 18789 18790
CMD ["clawdbot", "gateway", "--port", "18789", "--bind", "lan", "--verbose"]
CMD ["openclaw", "gateway", "--port", "18789", "--bind", "lan", "--verbose"]
-16
View File
@@ -1,16 +0,0 @@
#!/bin/bash
set -e
# Always update config to ensure trustedProxies is set for k8s ingress
# Using clawdbot.json (default config name) instead of moltbot.json
# Config includes:
# - trustedProxies: k8s pod network CIDRs for nginx ingress
# - controlUi.allowInsecureAuth: true - allows token-only auth behind reverse proxy
# - auth.mode: token - requires gateway token for authentication
echo '{"gateway":{"mode":"local","bind":"lan","port":18789,"trustedProxies":["10.42.0.0/16","10.43.0.0/16"],"controlUi":{"allowInsecureAuth":true},"auth":{"mode":"token"}},"agents":{"defaults":{"workspace":"/home/node/clawd"}}}' > /home/node/.clawdbot/clawdbot.json
echo "Clawdbot config written:"
cat /home/node/.clawdbot/clawdbot.json
echo "Starting clawdbot gateway..."
exec "$@"