Admin guide Setup
Configuration
Every environment variable the Archipelego server reads, with its default and its effect.
On this page
Archipelego reads its settings from environment variables when it starts. There is no configuration file. Restart the server after you change a variable.
Environment variables
| Variable | Default | Effect |
|---|---|---|
PORT |
1234 |
The port the server listens on, for the app, the websockets and the API. |
ARCHIPELEGO_DATA |
server/data from source, /data in the Docker image |
The folder for canvases, stored keys and the vault key. The server creates it if it is missing. |
ARCHIPELEGO_LIBRARY |
server/library |
The folder of reference architectures, one JSON file each. |
ARCHIPELEGO_RECIPES |
on |
The cookbook's community features: on, read (no publishing, proofs or comments) or off (no votes either). See Reference library. |
ARCHIPELEGO_MCP |
on | off turns off the MCP server for AI tools at /mcp. See MCP server for AI tools. |
ARCHIPELEGO_PUBLIC_URL |
the request's address | The canonical address of the instance, used by the MCP server (metadata, token audience, board links). |
ARCHIPELEGO_APP_URL |
ARCHIPELEGO_PUBLIC_URL |
Where the app's consent page for AI tools (/connect) lives, if different. |
ARCHIPELEGO_MCP_ORIGINS |
any | Browser origins allowed to call /mcp, separated by commas. |
ARCHIPELEGO_OPENAI_APPS_CHALLENGE |
none | The ChatGPT directory's domain token, served at /.well-known/openai-apps-challenge. |
ARCHIPELEGO_LLM_CATALOG |
server/llm/catalog.json |
The model catalog file the router reads. |
ARCHIPELEGO_SECRET |
not set | The master key that encrypts AI keys stored on the server. 32 bytes, as base64 or as 64 hexadecimal characters. When it is not set, the server creates a random key file, .vault.key, in the data folder. |
ARCHIPELEGO_PLATFORM_AI |
not set | on lets the server use its own Anthropic credentials for every canvas. off forces bring-your-own-key only. Not set: the server uses its own credentials only when an Anthropic variable below is set. |
ANTHROPIC_API_KEY |
not set | The server's own Anthropic key. Every canvas can use it as a last resort, unless ARCHIPELEGO_PLATFORM_AI=off. |
ARCHIPELEGO_AI_MOCK |
not set | The offline simulator. on answers @architect and drafts features without AI when no provider has a key. always uses the simulator for every request, even when keys exist. See Offline simulator. |
ARCHIPELEGO_MCP_SERVERS |
not set | Remote MCP servers whose apps appear in the chat, as name=url pairs separated by commas. See MCP servers. |
ARCHIPELEGO_DOCS |
docs-site/dist |
The folder of the built documentation site, served at /docs/. See Documentation site. |
The router also reads two more Anthropic variables. Each one counts as server credentials, like ANTHROPIC_API_KEY:
ANTHROPIC_AUTH_TOKENANTHROPIC_PROFILE
With ARCHIPELEGO_PLATFORM_AI=on, the server also uses an ant auth login profile on the machine.
Development only
| Variable | Default | Effect |
|---|---|---|
ARCHIPELEGO_SERVER |
http://localhost:1234 |
Where the Vite dev server on port 5173 sends /api, /docs and /yjs requests. It is not used in production. |
Offline simulator
The offline simulator stands in for the Architect when there is no AI. Use it for workshops without keys, for demos and for tests. It reads only the canvas, the blocks, their kinds and their connections, and the words of the request, so it never invents blocks.
| Value | Effect |
|---|---|
| not set, or any other value | Off. Without a key, the Architect says that no AI provider is connected. |
on |
The simulator answers when no provider has a key. As soon as a key works, the real model answers. 1 and true mean the same. |
always |
The simulator answers every @architect question and every feature draft, even when keys exist. |
- The simulator covers
@architectanswers and feature drafts. Explain still needs an AI provider. - Its answers say "Offline simulator" in the chat. The model badge shows the letter S.
- It sends nothing outside the server.
ARCHIPELEGO_AI_MOCK=on npm startMCP servers
The chat can show MCP Apps: interactive pages that an MCP server offers with its tools. Archipelego has one built-in server, archipelego, with the Canvas overview app. Only you, the administrator, can add remote servers. Participants cannot make the server call an address of their choice.
Set ARCHIPELEGO_MCP_SERVERS to a comma-separated list of name=url pairs:
ARCHIPELEGO_MCP_SERVERS="tickets=https://mcp.example.com/mcp,maps=https://maps.example.com/mcp"- The name has 1 to 40 letters, digits,
_or-. The chat shows it as the source of each app.archipelegois reserved for the built-in server. - The URL is the server's Streamable HTTP endpoint. Use
https://. - Pairs that do not match this format are ignored.
- The server connects to each remote server the first time someone opens the Apps menu or opens one of its apps.
- The Apps menu lists the tools that declare a
ui://resource, from_meta.ui.resourceUrior the ChatGPT Apps SDK keyopenai/outputTemplate. - Each request to a remote server times out after 20 seconds. A server that does not answer offers no apps. The rest of the chat keeps working.
Restart the server after you change the list. Read Security before you connect a server.
Documentation site
The server serves this documentation at /docs/. A request for /docs redirects to /docs/.
- The Docker image and the one-line installers build the site for you.
- From source, build it once with
npm installandnpm run buildindocs-site/. The output goes todocs-site/dist. - Set
ARCHIPELEGO_DOCSto serve a site built elsewhere. The site must be built for the base path/docs/. - When the folder is missing,
/docs/answers "The documentation is not built. Run npm run build in docs-site."
Paths
Relative paths resolve against the working folder of the server process. npm start runs the server in server/, so a relative path starts there. Use absolute paths to avoid surprises.
The defaults are relative to the server code, not to your current folder:
server/datafor the dataserver/libraryfor the libraryserver/llm/catalog.jsonfor the catalogdocs-site/distfor the documentation site
Generate a secret
ARCHIPELEGO_SECRET must decode to exactly 32 bytes. Generate one with OpenSSL:
openssl rand -base64 32Or with Node:
node -e "console.log(require('crypto').randomBytes(32).toString('base64'))"Keep the value in a password manager. If you lose it, the server cannot decrypt the keys stored for each canvas. People then add their keys again.
Set variables
With docker run
Add one -e option per variable:
docker run -d --name archipelego -p 1234:1234 -v archipelego-data:/data \
-e ARCHIPELEGO_SECRET=your-base64-secret \
-e ARCHIPELEGO_PLATFORM_AI=off \
ghcr.io/yannickhuchard/archipelego:latestTo change a variable later, remove the container and run it again with the same volume. See Upgrading.
With Docker Compose
Put the variables in a .env file next to compose.yaml:
ARCHIPELEGO_SECRET=your-base64-secret
ANTHROPIC_API_KEY=sk-ant-...
ARCHIPELEGO_PORT=1234
ARCHIPELEGO_TAG=latestThen run docker compose up -d again. ARCHIPELEGO_PORT and ARCHIPELEGO_TAG belong to compose.yaml, not to the server. Inside the container, the server always listens on 1234 and stores data in /data.
In a shell
On macOS and Linux:
PORT=8080 ARCHIPELEGO_DATA=/var/lib/archipelego npm startOn Windows, in PowerShell:
$env:PORT = "8080"
$env:ARCHIPELEGO_DATA = "D:\archipelego-data"
npm start