Migrate to OpenClaw 2026.1.29 (keep clawdbot shim); bump 0.4.8

This commit is contained in:
root
2026-01-30 16:46:10 +02:00
parent f5718000ed
commit 75efb8c6c1
5 changed files with 27 additions and 9 deletions
+5 -2
View File
@@ -42,9 +42,12 @@ RUN set -eu; \
libstdc++ libgcc libatomic; \
/usr/local/bin/node -v; /usr/local/bin/npm -v
# Install clawdbot globally
# Install OpenClaw globally (successor of Clawdbot)
# We also provide a lightweight `clawdbot` shim for backwards compatibility.
RUN npm config set fund false && npm config set audit false \
&& npm install -g clawdbot
&& npm install -g openclaw@2026.1.29 \
&& printf '%s\n' '#!/usr/bin/env sh' 'exec openclaw "$@"' > /usr/local/bin/clawdbot \
&& chmod +x /usr/local/bin/clawdbot
COPY run.sh /run.sh
COPY nginx.conf.tpl /etc/nginx/nginx.conf.tpl
+1 -1
View File
@@ -1,5 +1,5 @@
name: Moltbot Assistant
version: "0.4.7"
version: "0.4.8"
slug: moltbot_assistant
description: Run Moltbot Assistant (Clawdbot-compatible) as a Home Assistant add-on.
url: https://github.com/techartdev/MoltBotHomeAssistant
+19 -4
View File
@@ -149,7 +149,9 @@ if [ -z "$GW_TOKEN" ]; then
GW_AUTH_BLOCK="auth: { mode: \"token\" }"
fi
# Write Clawdbot gateway config (JSON5) into the expected location.
# Write gateway config (JSON5).
# We keep legacy Clawdbot paths for compatibility, and also write OpenClaw paths.
mkdir -p /config/.clawdbot /config/.openclaw
cat > /config/.clawdbot/clawdbot.json <<EOF
{
discovery: { wideArea: { enabled: false } },
@@ -184,6 +186,9 @@ cat > /config/.clawdbot/clawdbot.json <<EOF
}
EOF
# Also write OpenClaw config path(s) (best-effort; OpenClaw can auto-migrate legacy paths).
cp -f /config/.clawdbot/clawdbot.json /config/.openclaw/openclaw.json 2>/dev/null || true
echo "Model primary=${MODEL_PRIMARY}"
echo "Gateway bind=${GW_BIND} port=${GW_PORT} token=${GW_TOKEN:+(set)}${GW_TOKEN:-(auto)}"
echo "Telegram dmPolicy=${DM_POLICY}${ALLOW_FROM_RAW:+ (allowFrom=${ALLOW_FROM_RAW})}"
@@ -229,7 +234,7 @@ RUN_DOCTOR=$(jq -r '.run_doctor_on_start // false' "$OPTIONS_FILE")
if [ "$RUN_DOCTOR" = "true" ]; then
echo "Running assistant doctor (auto-fix) ..."
(timeout 60s clawdbot doctor --fix --yes) || true
(timeout 60s "${CLI_BIN:-clawdbot}" doctor --fix --yes) || true
else
echo "Skipping clawdbot doctor on startup (run_doctor_on_start=false)"
fi
@@ -267,8 +272,18 @@ trap shutdown INT TERM
NGINX_PID=""
TTYD_PID=""
echo "Starting Moltbot Assistant gateway (clawdbot-compatible)..."
clawdbot gateway run &
CLI_BIN=""
if command -v openclaw >/dev/null 2>&1; then
CLI_BIN="openclaw"
elif command -v clawdbot >/dev/null 2>&1; then
CLI_BIN="clawdbot"
else
echo "ERROR: Neither openclaw nor clawdbot is installed."
exit 1
fi
echo "Starting Moltbot Assistant gateway (${CLI_BIN}-compatible)..."
"${CLI_BIN}" gateway run &
GW_PID=$!
# Start web terminal (optional)