From 00df35531604b60b52a7451e48d49dee380f3f30 Mon Sep 17 00:00:00 2001 From: root Date: Fri, 30 Jan 2026 17:21:19 +0200 Subject: [PATCH] Rename Moltbot/Clawdbot to OpenClaw; drop back-compat; bump add-on to 0.5.0 --- DOCS.md | 8 ++-- README.md | 10 ++--- .../.gitignore | 0 .../Dockerfile | 9 ++--- .../build.yaml | 0 .../config.yaml | 14 +++---- .../icon.png | Bin .../logo.png | Bin .../nginx.conf.tpl | 4 +- .../run.sh | 36 ++++++++---------- repository.yaml | 4 +- 11 files changed, 39 insertions(+), 46 deletions(-) rename {moltbot_assistant => openclaw_assistant}/.gitignore (100%) rename {moltbot_assistant => openclaw_assistant}/Dockerfile (81%) rename {moltbot_assistant => openclaw_assistant}/build.yaml (100%) rename {moltbot_assistant => openclaw_assistant}/config.yaml (89%) rename {moltbot_assistant => openclaw_assistant}/icon.png (100%) rename {moltbot_assistant => openclaw_assistant}/logo.png (100%) rename {moltbot_assistant => openclaw_assistant}/nginx.conf.tpl (97%) rename {moltbot_assistant => openclaw_assistant}/run.sh (89%) diff --git a/DOCS.md b/DOCS.md index 28ffaee..53bcc05 100644 --- a/DOCS.md +++ b/DOCS.md @@ -1,8 +1,8 @@ -# Moltbot Assistant (Home Assistant Add-on) +# OpenClaw Assistant (Home Assistant Add-on) -This add-on runs a Moltbot Assistant instance on Home Assistant OS (Supervisor add-on). +This add-on runs a OpenClaw Assistant instance on Home Assistant OS (Supervisor add-on). -> Note: The upstream project has gone through renames. This add-on currently installs **OpenClaw** (the successor of Clawdbot) and also provides a `clawdbot` shim for backwards compatibility. +> Note: The upstream project has gone through renames. This add-on installs **OpenClaw**. ## What this add-on provides @@ -22,7 +22,7 @@ we open it directly using a user-provided public/base URL. 1. Home Assistant → Settings → Add-ons → Add-on store 2. Add repository URL: - Add-on store → ⋮ → Repositories → paste the GitHub repo URL -3. Install **Moltbot Assistant** +3. Install **OpenClaw Assistant** ## Configuration overview All configuration is done via the add-on UI (Options). diff --git a/README.md b/README.md index dcec268..162832d 100644 --- a/README.md +++ b/README.md @@ -1,8 +1,8 @@ -# Moltbot Assistant – Home Assistant Add-on (Draft) +# OpenClaw Assistant – Home Assistant Add-on (Draft) -This repository contains a Home Assistant add-on that runs a **Moltbot Assistant** instance on **HAOS**. +This repository contains a Home Assistant add-on that runs an **OpenClaw Assistant** instance on **HAOS**. -Upstream note: the project has gone through renames. This add-on currently installs **OpenClaw** and keeps a `clawdbot` shim for backwards compatibility. +Upstream note: the project has gone through renames. This add-on installs **OpenClaw**. ## What you get - Always-on personal assistant running as a Supervisor-managed container @@ -18,7 +18,7 @@ Upstream note: the project has gone through renames. This add-on currently insta ## Install (high level) 1. Add this repo in Home Assistant: Settings → Add-ons → Add-on Store → ⋮ → Repositories -2. Install **Moltbot Assistant** +2. Install **OpenClaw Assistant** 3. Configure options (at minimum: Telegram bot token) ## Setup / Docs @@ -28,7 +28,7 @@ See **DOCS.md** for the supported setups: ## Configuration All configuration is done via the add-on UI. -See the schema in `moltbot_assistant/config.yaml`. +See the schema in `openclaw_assistant/config.yaml`. ### Optional: Brave Search If you provide `brave_api_key`, the add-on exports `BRAVE_API_KEY` for the assistant’s web search tool. diff --git a/moltbot_assistant/.gitignore b/openclaw_assistant/.gitignore similarity index 100% rename from moltbot_assistant/.gitignore rename to openclaw_assistant/.gitignore diff --git a/moltbot_assistant/Dockerfile b/openclaw_assistant/Dockerfile similarity index 81% rename from moltbot_assistant/Dockerfile rename to openclaw_assistant/Dockerfile index b48600d..b9d9db1 100644 --- a/moltbot_assistant/Dockerfile +++ b/openclaw_assistant/Dockerfile @@ -2,7 +2,7 @@ ARG BUILD_FROM=ghcr.io/hassio-addons/base:14.0.2 FROM ${BUILD_FROM} # Base image is Alpine (HA add-ons base). It may only provide Node 18.x. -# Clawdbot requires Node 20+, so we install a Node 20 musl build directly. +# OpenClaw requires Node 20+, so we install a Node 20 musl build directly. ARG NODE_VERSION=22.12.0 RUN apk add --no-cache \ @@ -42,12 +42,9 @@ RUN set -eu; \ libstdc++ libgcc libatomic; \ /usr/local/bin/node -v; /usr/local/bin/npm -v -# Install OpenClaw globally (successor of Clawdbot) -# We also provide a lightweight `clawdbot` shim for backwards compatibility. +# Install OpenClaw globally RUN npm config set fund false && npm config set audit false \ - && 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 + && npm install -g openclaw@2026.1.29 COPY run.sh /run.sh COPY nginx.conf.tpl /etc/nginx/nginx.conf.tpl diff --git a/moltbot_assistant/build.yaml b/openclaw_assistant/build.yaml similarity index 100% rename from moltbot_assistant/build.yaml rename to openclaw_assistant/build.yaml diff --git a/moltbot_assistant/config.yaml b/openclaw_assistant/config.yaml similarity index 89% rename from moltbot_assistant/config.yaml rename to openclaw_assistant/config.yaml index fdd161a..8fd3e6d 100644 --- a/moltbot_assistant/config.yaml +++ b/openclaw_assistant/config.yaml @@ -1,8 +1,8 @@ -name: Moltbot Assistant -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 +name: OpenClaw Assistant +version: "0.5.0" +slug: openclaw_assistant +description: Run OpenClaw Assistant (OpenClaw-compatible) as a Home Assistant add-on. +url: https://github.com/techartdev/OpenClawHomeAssistant arch: - amd64 startup: services @@ -15,7 +15,7 @@ host_network: true # Home Assistant Ingress (UI inside the add-on page) ingress: true ingress_port: 8099 -panel_title: Moltbot Assistant +panel_title: OpenClaw Assistant panel_icon: mdi:robot map: @@ -43,7 +43,7 @@ options: # Example: "https://example.duckdns.org:12345" or "http://192.168.1.10:18789" gateway_public_url: "" - # Run `clawdbot doctor --fix` on startup (useful after upgrades; slows restarts) + # Run `openclaw doctor --fix` on startup (useful after upgrades; slows restarts) run_doctor_on_start: false homeassistant_token: "" diff --git a/moltbot_assistant/icon.png b/openclaw_assistant/icon.png similarity index 100% rename from moltbot_assistant/icon.png rename to openclaw_assistant/icon.png diff --git a/moltbot_assistant/logo.png b/openclaw_assistant/logo.png similarity index 100% rename from moltbot_assistant/logo.png rename to openclaw_assistant/logo.png diff --git a/moltbot_assistant/nginx.conf.tpl b/openclaw_assistant/nginx.conf.tpl similarity index 97% rename from moltbot_assistant/nginx.conf.tpl rename to openclaw_assistant/nginx.conf.tpl index 551821a..7f68c2e 100644 --- a/moltbot_assistant/nginx.conf.tpl +++ b/openclaw_assistant/nginx.conf.tpl @@ -54,7 +54,7 @@ http { # (Nabu Casa, DuckDNS, LAN, etc.). return 200 ' - Moltbot Assistant + OpenClaw Assistant
-

Moltbot Assistant

+

OpenClaw Assistant

Open Gateway Web UI Open Terminal (full page) diff --git a/moltbot_assistant/run.sh b/openclaw_assistant/run.sh similarity index 89% rename from moltbot_assistant/run.sh rename to openclaw_assistant/run.sh index 0cd4be8..22e0313 100644 --- a/moltbot_assistant/run.sh +++ b/openclaw_assistant/run.sh @@ -49,9 +49,9 @@ export TZ="$TZNAME" set +x # HA add-ons mount persistent storage at /config (maps to /addon_configs/ on the host). -# Use /config as HOME so Clawdbot finds its auth store and config there. +# Use /config as HOME so OpenClaw finds its auth store and config there. export HOME=/config -mkdir -p /config/.clawdbot /config/clawd /config/keys /config/secrets +mkdir -p /config/.openclaw /config/clawd /config/keys /config/secrets # Back-compat: some docs/scripts assume /data; point it at /config. if [ ! -e /data ]; then @@ -59,12 +59,12 @@ if [ ! -e /data ]; then fi # Ensure these exist so cleanup doesn't fail -mkdir -p /config/.clawdbot/agents/main/sessions || true +mkdir -p /config/.openclaw/agents/main/sessions || true # ------------------------------------------------------------------------------ # SINGLE-INSTANCE GUARD (prevents multiple gateway runs racing each other) # ------------------------------------------------------------------------------ -STARTUP_LOCK="/config/.clawdbot/gateway.start.lock" +STARTUP_LOCK="/config/.openclaw/gateway.start.lock" exec 9>"$STARTUP_LOCK" if ! flock -n 9; then echo "ERROR: Another instance appears to be running (could not acquire $STARTUP_LOCK)." @@ -78,11 +78,11 @@ fi # Returns 0 if a gateway process appears to be running, else 1 gateway_running() { - pgrep -f "clawdbot.*gateway.*run" >/dev/null 2>&1 + pgrep -f "openclaw.*gateway.*run" >/dev/null 2>&1 } cleanup_session_locks() { - local sessions_dir="/config/.clawdbot/agents/main/sessions" + local sessions_dir="/config/.openclaw/agents/main/sessions" local glob1="${sessions_dir}"/*.jsonl.lock shopt -s nullglob @@ -121,7 +121,7 @@ if [ -n "$HA_TOKEN" ]; then printf '%s' "$HA_TOKEN" > /config/secrets/homeassistant.token fi -# Brave Search API key (for clawdbot's web_search tool, which reads BRAVE_API_KEY) +# Brave Search API key (for OpenClaw's web_search tool, which reads BRAVE_API_KEY) if [ -n "$BRAVE_KEY" ]; then export BRAVE_API_KEY="$BRAVE_KEY" umask 077 @@ -150,9 +150,8 @@ if [ -z "$GW_TOKEN" ]; then fi # 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 < /config/.openclaw/openclaw.json < /config/.clawdbot/clawdbot.json </dev/null || true +# OpenClaw reads its config from /config/.openclaw/openclaw.json echo "Model primary=${MODEL_PRIMARY}" echo "Gateway bind=${GW_BIND} port=${GW_PORT} token=${GW_TOKEN:+(set)}${GW_TOKEN:-(auto)}" @@ -195,7 +193,7 @@ echo "Telegram dmPolicy=${DM_POLICY}${ALLOW_FROM_RAW:+ (allowFrom=${ALLOW_FROM_R echo "Telegram allowFrom JSON: ${ALLOW_FROM_JSON:-}" # Auth store debug (redacted): never print tokens -AUTH_STORE="/config/.clawdbot/agents/main/agent/auth-profiles.json" +AUTH_STORE="/config/.openclaw/agents/main/agent/auth-profiles.json" if [ -f "$AUTH_STORE" ]; then echo "Auth store present at $AUTH_STORE" echo "Auth store summary (redacted):" @@ -234,9 +232,9 @@ RUN_DOCTOR=$(jq -r '.run_doctor_on_start // false' "$OPTIONS_FILE") if [ "$RUN_DOCTOR" = "true" ]; then echo "Running assistant doctor (auto-fix) ..." - (timeout 60s "${CLI_BIN:-clawdbot}" doctor --fix --yes) || true + (timeout 60s "${CLI_BIN:-openclaw}" doctor --fix --yes) || true else - echo "Skipping clawdbot doctor on startup (run_doctor_on_start=false)" + echo "Skipping doctor on startup (run_doctor_on_start=false)" fi # ------------------------------------------------------------------------------ @@ -275,14 +273,12 @@ TTYD_PID="" 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." + echo "ERROR: openclaw is not installed." exit 1 fi -echo "Starting Moltbot Assistant gateway (${CLI_BIN}-compatible)..." +echo "Starting OpenClaw Assistant gateway (${CLI_BIN}-compatible)..." "${CLI_BIN}" gateway run & GW_PID=$! @@ -305,7 +301,7 @@ fi # Render nginx config from template with the gateway token. # NOTE: This intentionally exposes the token in the browser URL via a redirect. -# This matches Clawdbot Control UI's current expectations. +# This matches OpenClaw Control UI's current expectations. GW_TOKEN="$GW_TOKEN" GW_PUBLIC_URL="$GW_PUBLIC_URL" python3 - <<'PY' import os from pathlib import Path diff --git a/repository.yaml b/repository.yaml index 98a6057..e2ee5ea 100644 --- a/repository.yaml +++ b/repository.yaml @@ -1,3 +1,3 @@ -name: Moltbot Assistant Add-ons -url: https://github.com/techartdev/MoltBotHomeAssistant +name: OpenClaw Assistant Add-ons +url: https://github.com/techartdev/OpenClawHomeAssistant maintainer: Vanyo