Skip to content

v1.2.65

Latest

Choose a tag to compare

@robsonfelix robsonfelix released this 09 Jul 02:24

Add-on version 1.2.65. This is the Home Assistant add-on's own version, not Anthropic's Claude Code CLI version. The CLI is installed at build time by resolving the newest release that actually runs on your hardware — currently 2.1.205 on a CPU with AVX, or 2.1.112 on one without. No CLI version is pinned.

Security

  • The Supervisor token is no longer written to settings.json. update_mcp_token() in .bashrc wrote $SUPERVISOR_TOKEN into /homeassistant/.claudecode/settings.json on every c/cc, persisting a live credential into the HA config directory — which is included in every backup. The key was also dead: hass-mcp reads HA_TOKEN from the environment, which the add-on already exports, and never reads HASS_TOKEN. The function is removed and any previously persisted token is scrubbed once on startup
  • The token was also interpolated unescaped into a jq filter string
  • AppArmor now grants write access only to /usr/local/bin/** and /usr/local/lib/node_modules/** instead of all of /usr/local/**

Fixed

  • Add-on failed to start on CPUs without AVX (#24). Claude Code 2.1.113 replaced its JavaScript entrypoint with a Bun-compiled native binary, and Bun's JavaScriptCore requires AVX. On a VM exposing the generic kvm64 CPU model every claude invocation hangs — including claude --version — which blocked startup before ttyd bound port 7681, leaving the add-on unhealthy with a near-empty log.

    Fix this at the hypervisor: set the VM CPU type to host (Proxmox) or enable host CPU passthrough, then fully stop and start the VM. Verify with grep -o -m1 avx2 /proc/cpuinfo. Until then the build falls back to 2.1.112, the last release that ran as JavaScript under Node. See anthropics/claude-code#19981 and oven-sh/bun#26353.

  • auto_update_claude never worked (#22, #13). AppArmor granted /usr/local/** ixr, so npm could not write its own global prefix and failed with EACCES on rename even as root. 2>/dev/null hid the error on every boot.

  • Build failed with unknown instruction: set (#19). Heredocs in RUN need BuildKit plus a # syntax=docker/dockerfile:1.4 directive; the shell configs are now plain COPY from rootfs/.

  • Build aborted on a transient DNS failure (#23). ha and ttyd downloads now retry, and the Home Assistant CLI is pinned to 5.2.0.

  • Build failed on armv7/armhf/i386 with a 404 — upstream publishes the ha CLI only for amd64 and aarch64; those arches now skip it with a warning.

  • settings.json is bootstrapped with {} when missing, so the pre-authorized tool list is actually applied on fresh installs.

  • enable_mcp and session_persistence could not be turned off. Both were read with jq -r '.option // true', and jq's // falls back on false as well as null, so a disabled option resolved back to true. Setting session_persistence: false now really does drop tmux, restoring native browser scrolling and copy/paste (#14, #20, #25).

Added

  • install-claude.sh resolves the newest Claude Code release that passes a claude --version smoke test. It takes latest when latest works, binary-searches for the newest working release when it does not, and fails the build if none do. No version is hardcoded.
  • Startup health gate: if the CLI does not respond within 30s, MCP setup is skipped and the terminal starts anyway, so a broken CLI no longer presents as "add-on won't start".
  • Automatic rollback to the build-verified version when auto_update_claude installs a release that cannot run.
  • Startup warns when the CPU lacks AVX and explains the hypervisor fix.
  • Persistent tmux overrides (#25): /homeassistant/.claudecode/tmux.conf is sourced last and survives restarts, rebuilds and reinstalls. For example echo 'set -g mouse off' > /homeassistant/.claudecode/tmux.conf.

Changed

  • The unpinned npm install -g @anthropic-ai/claude-code is replaced by the resolver above, so a rebuild can no longer silently swap in a release that does not run.
  • claude mcp calls are wrapped in timeout; a hang can no longer block startup.
  • Startup no longer discards npm's stderr.

Also in this release cycle: Playwright Browser 0.1.12 fixes the apt-get: not found build failure (#35, #28). Supervisor's build_from regex rejected mcr.microsoft.com/playwright (single path segment), silently fell back to the Alpine HA base, and apt-get did not exist there. Credit to @sergiorademacher (#31).

Fixes #24, #22, #19, #23, #13, #26. Credit to @adebree for independently identifying the Proxmox cpu: host fix in #24, and to @apbb2 for flagging the persisted Supervisor token.