Skip to content

Configuration ​

All server options and defaults are defined in internal/server/config/config.go. The server reads process environment variables; it does not automatically load an .env file.

Frequently adjusted settings ​

VariablePurpose / default
LOOP_NOW_LISTEN_ADDRConsole API; 127.0.0.1:8780
LOOP_NOW_DATA_DIRDatabase (db/) and daily backups (backups/); ~/.loop_now of the server user
LOOP_NOW_WORK_ROOTPersistent agent workspaces and runtime files; like the data directory, one server instance at a time (locked by .loop-now-server.lock)
LOOP_NOW_CONTEXT_DIRShared project (projects/<id>/) and global (global/) context folders; ~/.loop_now of the server user
LOOP_NOW_PLUGIN_HOST_ENTRYAbsolute path of the plugin host entry run with Node; unset means plugins' platform sides do not run
LOOP_NOW_PLUGIN_OFFICIAL_DIRAbsolute path of the official plugins shipped with the platform (one directory per plugin); unset means no builtin install source
LOOP_NOW_PLUGIN_MARKET_URLhttps address of the official plugin market's loop-now-market.json; defaults to the official market index and can point elsewhere
LOOP_NOW_PI_MAX_PROCESSES0 means unlimited; a positive value caps local Pi processes
LOOP_NOW_PI_IDLE_TIMEOUTIdle Pi process timeout; 10m
LOOP_NOW_CONSOLE_ORIGINSCross-origin browser origins allowed to call the API, for the Vite dev server; local port 5173 by default, none allows none. The console the server serves itself is same-origin and needs no entry
LOOP_NOW_LARK_USER_BUNDLE_DIROptional verified Lark user CLI bundle

Data directory and backups ​

The database is SQLite: data.db holds platform state and credentials (in plaintext), events.db holds run and audit logs. Only one server may use a data directory at a time. Every day the server checkpoints the database, removes run and audit logs older than 90 days, and writes a backup.

VariablePurpose / default
LOOP_NOW_DATA_DIRData directory; ~/.loop_now of the server user
LOOP_NOW_BACKUP_DIRWhere daily backups go, one dated subdirectory each; <data directory>/backups
LOOP_NOW_BACKUP_KEEPHow many daily backups to keep; 7

loop-server backup <directory> writes a backup on demand, also while the server runs. loop-server import-postgres moves an installation from a PostgreSQL-based release once (see Getting started).

Required for a source installation ​

VariablePurpose
LOOP_NOW_NODE_BINPath of the Node binary used to run the plugin host
LOOP_NOW_PI_BINPath of the Pi coding agent binary
LOOP_NOW_LOOPCTL_DIST_DIRDirectory holding the matching-version loopctl distribution (a release bundle uses the one next to loop-server)

Release bundle and desktop shell ​

A release bundle (scripts/release/build.sh, or the release workflow) unpacks to one directory:

PathContents
loop-serverThe server, with the console built in and served on its port at /
loopctl-dist/loopctl for every platform
plugins/host/main.js, plugins/official/Plugin host and official plugins
runtime/node/Node 24.21.0 with npm
runtime/pi/Pi coding agent 1.4.0 installed with that Node

When LOOP_NOW_NODE_BIN, LOOP_NOW_PI_BIN, LOOP_NOW_LOOPCTL_DIST_DIR, LOOP_NOW_PLUGIN_HOST_ENTRY or LOOP_NOW_PLUGIN_OFFICIAL_DIR is unset and the matching file sits next to loop-server, the server uses it, so the machine needs no Node or Pi of its own. The configured Node's directory comes first on the agents' PATH.

VariablePurpose
LOOP_NOW_WEB_DIRServe the console from this directory instead of the built-in one
LOOP_NOW_READY_FILEOnce serving, write {"url","pid","version"} to this file (removed on shutdown); use it with LOOP_NOW_LISTEN_ADDR=127.0.0.1:0 to learn the port. Readiness: GET <url>/healthz

Exit codes of loop-server: 0 normal shutdown, 1 other startup failure or an error while shutting down, 2 invalid configuration, 3 the data directory or the work root is used by another instance, 4 a listen address is already in use.

Security boundaries ​

The current release is intended for trusted personal use:

  • The console has no authentication. Keep it on loopback rather than exposing it to a public network.
  • Agents execute local commands under the server's operating-system user. A separate task directory is not an OS security sandbox.
  • Plugins execute code; install sources you trust. Model and tool access also depends on the credentials and permissions you provide.
  • Conversation history is persistent, but a server restart is not a promise of uninterrupted execution or automatic replay of in-flight work. Prefer updating when agents are idle.

Released under the Apache-2.0 License.