Configuration
Configure server identity, networking, authentication, and storage.
Codevisor Server currently uses command-line flags rather than a configuration file.
codevisor-server serve \
--host 0.0.0.0 \
--port 49361 \
--auth token \
--serverId build-box \
--name "Build box" \
--kind remote| Flag | Description | Default |
|---|---|---|
--host | Bind address | 127.0.0.1 |
--port | HTTP, SSE, and WebSocket port | Automatic (see below) |
--preferred-port | First port to try without --port | 49361 |
--auth | none or token | none for 127.0.0.1; otherwise token |
--serverId | Protocol-facing server ID | local |
--name | Human-readable machine name | Local Codevisor on loopback; hostname otherwise |
--kind | local or remote | local for 127.0.0.1; otherwise remote |
--db | SQLite database path | ~/.codevisor/data/codevisor-server.sqlite |
--upgrade-status | Data-migration status file | data-upgrade.json beside the database |
Listening port
Without --port or CODEVISOR_PORT, the server defaults to 49361 and falls back to a free port
in the range 49361–49399 when another app holds it. It first tries the port it used last time,
so the port stays stable across restarts. Only if the whole range is taken does it let the
operating system pick a port. The server records the port it chose in server-port.json in its
data directory, and the codevisor CLI and the Codevisor app read it from there.
--port or CODEVISOR_PORT pins the port exactly: the server fails to start rather than move.
The Linux installer and systemd units pin the port this way, so remote clients keep a fixed
address.
CODEVISOR_DATA_DIR changes the default data directory. An explicit --db wins. The canonical
layout is:
| Path | Contents |
|---|---|
~/.codevisor/data | SQLite, attachments, keys, sidecar state |
~/.codevisor/server | Standalone installed runtime |
~/.codevisor/logs | Logs for non-systemd background runs |
~/.codevisor/repos | Codevisor-managed Git clones |
The CLI also accepts app-lifecycle flags such as --boot-id, --app-owned, and --owner-pid.
They coordinate a bundled desktop server and are not normal deployment settings.