setup¶
Run the full Openbase local installation flow.
In the apps: the desktop app's
guided setup runs this command for you (streaming its output via
--json-progress); the iOS app waits on its
completion during pairing.
Usage¶
Deployment Modes¶
Setup supports exactly two deployment modes and picks one automatically:
- Standalone (production): a bundled runtime package — shipped inside the
desktop app — containing Python, the CLI, LiveKit server, a prebuilt
console, agent instructions, and skills. Detected automatically via the
package's
openbase-coder-package.json. - Development: no runtime package is present, so setup runs against a
developer's
openbase-coder-workspacecheckout. Setup never clones or git-updates a workspace. With--workspace-diromitted it discovers the checkout from, in order: - the workspace recorded in
~/.openbase/installation.jsonby a prior install, then - the checkout behind an editable CLI install
(
uv tool install -e ./cli, via the package'sdirect_url.json).
If neither is found, setup errors and asks you to clone
openbase-coder-workspace (and run its ./scripts/setup), pass
--workspace-dir, or use the standalone install instead.
For normal macOS installs, prefer the desktop app: it activates the bundled
runtime automatically, and its guided flow runs openbase-coder setup for
you. To run setup yourself from a terminal instead, follow
Manual Setup for the Desktop App.
For development, run the workspace script from your checkout root; it runs
multi sync --install-set default and then
openbase-coder setup --workspace-dir <workspace-root>:
The workspace script is for a clean source-workspace install. If it finds an existing standalone install or a different development workspace install, it stops and directs you to Uninstall before making changes.
Backend Selection¶
Setup configures the default coding backend:
openbase-coder setup --backend codex
openbase-coder setup --backend claude-code
openbase-coder setup --backend openbase-cloud
codex: native Codex app-server with OpenAI models.claude-code: Claude Code backend using local Claude auth/billing for Super Agents UI-driver sessions.openbase-cloud: Codex-compatible sessions through the Openbase Cloud model proxy with Openbase login.
Codex and Claude Code are peers; there is no silent default. When creating a
new ~/.openbase/.env with --backend omitted, setup prompts interactively
for the backend, and errors in non-interactive runs (including
--json-progress) asking for an explicit --backend. Existing env files keep
their configured backend and are only changed when --backend is passed.
Setup installs the selected backend's CLI on demand if it is missing: codex
from its GitHub release binaries into ~/.openbase/bin, claude via
Anthropic's official native installer. Backend-specific services (such as
codex-app-server) are only installed for the backends that use them;
openbase-coder services status shows not used (<backend> backend) for
gated-out services.
With --audio-provider local, setup installs the optional Kokoro/MLX local
audio dependencies and downloads the required models. Standalone packages
should be built with Python 3.12 for this path because Kokoro currently
declares Python <3.13.
Options¶
| Option | Default | Description |
|---|---|---|
--workspace-dir PATH |
discovered | Development workspace checkout. When omitted, discovered from the recorded installation, then an editable CLI install; ignored in standalone mode |
--env-file PATH |
~/.openbase/.env |
Shared environment file path |
--assembly-ai-api-key TEXT |
env ASSEMBLY_AI_API_KEY |
Optional STT key |
--cartesia-api-key TEXT |
env CARTESIA_API_KEY |
Optional TTS key |
--skip-services |
false |
Skip background service installation |
--link-codex-config |
false |
Symlink Openbase's service Codex config to ~/.codex/config.toml. Warning: setup then writes Openbase's permission overrides (sandbox_mode = "danger-full-access" and a no-prompt approval policy) into that shared normal config |
--link-claude-config |
false |
Symlink Openbase's Claude settings to the normal ~/.claude/settings.json |
--fast-mode/--no-fast-mode |
true |
Use the fast service tier for the voice dispatcher. Super Agents stay on the standard tier; both are adjustable in console settings |
--backend NAME |
prompted for new env files | Default coding backend: codex, claude-code, or openbase-cloud. Existing env files are only changed when provided |
--audio-provider NAME |
openbase-cloud for new dispatcher configs |
Voice audio provider. Existing configs are only changed when provided |
--json-progress |
false |
Emit NDJSON step events on stdout for UI-driven setup; human-readable output moves to stderr |
Behavior Details¶
setup runs on macOS (launchd) and Linux (systemd user services) and performs these phases:
- Ensures
~/.openbaseexists, plus the thread-sync exchange folder and bundled sounds. - Detects the bundled runtime package (standalone mode), or resolves the development workspace checkout as described above. Never clones or updates a workspace.
- Writes
installation.jsonwith the active runtime paths andenv_file. - Creates
.envwith generated secrets if missing, recording the selected backend (prompted for when--backendis omitted). - Installs the selected backend's CLI binary on demand if missing (codex →
~/.openbase/bin, claude → Anthropic's installer). This is best-effort: on failure setup prints manual install instructions and continues. - For the codex/openbase-cloud backends, symlinks
~/.openbase/codex_home/auth.jsonto~/.codex/auth.jsonso service Codex sessions use the normal Codex login. - Links normal
~/.claude/CLAUDE.mdto~/.codex/AGENTS.md, preserving an existing real Claude instructions file by copying it into Codex AGENTS when Codex AGENTS is missing or backing it up when both files differ. - Regenerates
~/.openbase/codex_home/AGENTS.mdfrom the bundled package or workspaceinstructions/AGENTS.md. The generated file records its source template path and, by default, includes normal~/.codex/AGENTS.mdcontent above the Openbase section. - Links
~/.openbase/claude_config/CLAUDE.mdto Openbase's generated~/.openbase/codex_home/AGENTS.md. - Renders shared default instruction files from the bundled package or workspace
instructions/into~/.openbase/instructions/. - Creates missing
~/.openbase/dispatcher-config.jsonwith default dispatcher reasoning effortlow, default Super Agents reasoning efforthigh, and backend-specific default model settings. - Symlinks bundled or workspace skills into
~/.openbase/codex_home/skillsand~/.openbase/claude_config/skills. - Initializes runtime assets: in development mode runs
uv syncincli; in both modes downloads the LiveKit agent model files (VAD, turn detector) so the first voice session does not stall on downloads. - Installs the bundled
inject-session-id.shSessionStart hook script into~/.openbase/hooks/and registers it in both Openbase agent homes: ahooks.SessionStartentry in~/.openbase/claude_config/settings.jsonand a trusted[[hooks.SessionStart]]hook (with its[hooks.state]trust entry) in~/.openbase/codex_home/config.toml. The hook feeds each session's thread/session ID back into the conversation together with the instructions for using it, so agents stamp commits with theAgent-Thread-Idtrailer without needing any standingAGENTS.mdrule. - Configures
~/.openbase/codex_home/config.tomlwith full Codex local access (sandbox_mode = "danger-full-access"), disabled permission prompts, and the Super Agents MCP server. With--link-codex-config, this path is first linked to~/.codex/config.toml. The MCP command prefers the selected workspace's venv executable and falls back to the resolved localuvpath. - Configures
~/.openbase/claude_config/.claude.jsonwith the Super Agents MCP server and writesCLAUDE_CONFIG_DIR=~/.openbase/claude_configinto the shared.env. - Merges normal Claude Code state from
~/.claude.jsoninto~/.openbase/claude_config/.claude.json(the file Claude Code reads under Openbase'sCLAUDE_CONFIG_DIR) when available; existing Openbase values win andmcpServersentries are unioned. Claude Code OAuth uses config-dir-scoped credentials, so on macOS setup also copies the normal "Claude Code-credentials" keychain item to Openbase's config-dir-specific keychain service, inheriting the normal Claude login without a second browser OAuth. When--backend claude-codeis selected and no login could be bridged, setup runsopenbase-coder claude login. - Registers the Super Agents MCP server in the user's normal agent homes — a
[mcp_servers.super-agents]table in~/.codex/config.tomland anmcpServers.super-agentsentry in~/.claude.json— regardless of--link-codex-config. Only the MCP entry is written; normal permissions and settings are never touched. You may remove the entry; an explicit setup re-run restores it. - Installs or updates the
~/.local/bin/openbase-codershim: never overwrites auv tool install-managed script; in standalone mode it points at thecurrent/package launcher so it survives package upgrades; in development mode it execs the workspacecli/.venv/bin/openbase-coder. - Writes Codex app-server defaults like
CODEX_MODEL=gpt-5.5,CODEX_MODEL_REASONING_EFFORT=high,CODEX_SERVICE_TIER=standard,CODEX_APP_SERVER_URL, andLIVEKIT_CODEX_THREAD_CWDinto the shared.env. WhenOPENBASE_CODING_BACKEND=openbase_cloud, the app-server service switches to the Openbase Cloud model proxy at startup. - Uses the bundled console build, or builds
consolein development mode. - Installs background services (launchd on macOS, systemd user units on Linux) unless skipped. Services gated to other backends (e.g.
codex-app-serverunderclaude-code) are not installed. - Configures Tailscale Serve routes for the iOS app:
tailscale serve --bg --http=18080 http://127.0.0.1:7999tailscale serve --bg --tcp=7880 tcp://127.0.0.1:7880
- Leaves Openbase Cloud registration to the later login/pairing flow. Use
openbase-coder onboarding reportafteropenbase-coder loginwhen you need to register this device for iOS pairing. Seeonboarding.
JSON Progress¶
With --json-progress, setup emits one NDJSON event per line on stdout so a
UI (e.g. the Mac app's one-click setup) can render a live checklist; all
human-readable output — including subprocess output — is redirected to
stderr. Step ids, in order: workspace, installation_config, env,
agent_config, services, tailscale_serve.
{"event": "step", "id": "services", "status": "start", "detail": null}
{"event": "step", "id": "services", "status": "ok", "detail": null}
{"event": "step", "id": "tailscale_serve", "status": "warn", "detail": "tailscale was not found on PATH."}
{"event": "result", "ok": true, "cli_configured": true, "tailscale_serve_healthy": false}
warn steps are non-fatal. A hard failure emits a final error step event
and {"event": "result", "ok": false, ...}, and exits nonzero. The full
protocol is specified in the workspace specs/onboarding/README.md.
The generated env file records the selected backend as OPENBASE_CODING_BACKEND.
Example¶
Development-mode setup against an explicit checkout:
openbase-coder setup \
--workspace-dir ~/Projects/openbase-coder-workspace \
--env-file ~/.openbase/.env
Notes¶
- If
.envalready exists, setup leaves it unchanged (including the backend, unless--backendis passed). ~/.openbase/codex_home/AGENTS.mdis a generated regular file frominstructions/AGENTS.md; setup rewrites it and records the source template path. A console setting controls whether normal~/.codex/AGENTS.mdcontent is included above the Openbase section; the default is enabled.~/.openbase/claude_config/CLAUDE.mdis a symlink to~/.openbase/codex_home/AGENTS.md. Normal~/.claude/CLAUDE.mdis kept symlinked to~/.codex/AGENTS.md.- Shared default instruction files under
~/.openbase/instructionsare generated regular files with source-template comments. - If
dispatcher-config.jsonalready exists, setup preserves it. - Existing skill symlinks in
~/.openbase/codex_home/skillsand~/.openbase/claude_config/skillsare updated to the bundled or workspace source. Real skill directories or files are left unchanged. - Existing
~/.openbase/codex_home/config.tomlcontent is preserved, except setup enforces the root permission keys and creates or replaces the[mcp_servers.super-agents]table. Passing--link-codex-configmakes~/.openbase/codex_home/config.tomla symlink to~/.codex/config.toml; if the normal Codex config is missing, setup seeds it from the existing Openbase config before linking. Warning: once linked, the enforced Openbase permission keys (sandbox_mode = "danger-full-access"and the no-prompt approval policy) are written into that shared normal Codex config. - Independent of
--link-codex-config, setup always registers thesuper-agentsMCP server in the normal~/.codex/config.tomland~/.claude.json. This writes only the MCP entry — never Openbase permission overrides — and re-running setup restores the entry if it was removed. - If
npmoruvare missing in development mode, related steps are skipped with messages. - If Tailscale is missing or disconnected, setup prints the manual Serve
commands and continues.
openbase-coder doctorandopenbase-coder services statusfail until the Tailscale Serve routes and external Openbase health check pass.