Configure XTM One
Finish the setup of XTM One after the install, then set its secrets, public URL and proxy trust, language models, edition, platform links, mail, security headers and sizing.
XTM One starts with the rest of the XTM stack, as Install with Docker Compose describes. This page first takes it from running to usable: the reverse proxy it trusts, the first sign-in, a language model and its edition. It then sets the configuration a deployment of XTM One decides on: its secrets, its public URL, the language models, its edition, its links to the other platforms, mail, the security headers of its pages, its sandbox and the package mirror of the sandbox, and the size of its processes. Every setting here is an environment variable of the xtm-one and xtm-one-worker containers, read when they start. Read the XTM One configuration reference for every variable.
- .env → xtm-one: docker compose up -d
- docker-compose.override.yml → xtm-one: docker compose up -d
- .env → xtm-one-worker: same values
- Settings screens → xtm_one database: saved
- xtm_one database → xtm-one: unless a variable locks
What XTM One runs on
- Browser → xtm-one: through the reverse proxy
- OpenCTI and OpenAEV → xtm-one: register every 5 minutes
- xtm-one → PostgreSQL: its data
- xtm-one-worker → Redis: background jobs
- xtm-one-worker → S3 storage: files
- xtm-one → Language models: prompts
- xtm-one-worker → Language models: prompts
| Component | What XTM One needs | In xtm-docker |
|---|---|---|
| Images | xtmone/platform, the interface, the API and the chat on port 4000, and xtmone/worker, which runs the background work: assignments, schedules, knowledge base indexing. Both at the same version. They are published for linux/amd64 only | The xtm-one and xtm-one-worker services, always started |
| PostgreSQL | PostgreSQL 17 with the vector extension (pgvector) in its database. The extension needs a superuser to create it | The shared pgsql service: the xtm-one-db-init job creates the xtm_one database, its role XTM_ONE_POSTGRES_USER and the extension at each start |
| Redis | The queue of background jobs, the live chat, locks, rate limits and quota counters. It holds working state, not your data | The shared redis service |
| S3 storage | A bucket for uploaded documents, chat attachments, generated files and large trace payloads. XTM One creates it when it does not exist | The shared minio service, bucket XTM_ONE_S3_BUCKET (xtm-one-files) |
| A language model | At least one provider XTM One reaches, such as OpenAI, Anthropic, Google Gemini, Mistral AI, Azure OpenAI or AWS Bedrock, or a model on your network through Ollama, LiteLLM or an OpenAI-compatible endpoint | None: you add it after the first sign-in |
| An edition | AI agents and the chat run with the Enterprise Edition only: a Filigran license in XTM One, or a registered OpenCTI or OpenAEV that has one | XTM_ONE_ENTERPRISE_LICENSE, empty in .env.sample |
With the Community Edition, XTM One starts and its screens open, but the chat and the agents stay off. The MCP servers of the registered platforms work in both editions. See What each edition of XTM One brings.
Finish the setup after the install
Once the stack runs, with XTM One published on 127.0.0.1:8090 and a reverse proxy that serves xtm-one.example.com over HTTPS, these steps take XTM One from running to usable. Run their commands from the folder of the stack. Keep at hand an API key of a language model provider, or the address of a model served on your network, and a Filigran license certificate unless a registered OpenCTI or OpenAEV has one. xtm-docker builds the whole configuration of XTM One from .env. Three values decide what you cannot change later without trouble:
Variable of .env | What it is |
|---|---|
XTM_ONE_SECRET_KEY | Signs the sessions and the tokens XTM One sends to the other platforms, and encrypts the credentials it stores, such as the API keys of the language models. Never change it once XTM One has started: every credential it encrypted becomes unreadable |
XTM_ONE_ADMIN_EMAIL | The administrator account, created at the first start. It must be the admin email of OpenCTI and OpenAEV: XTM One finds a person in each platform by email |
XTM_ONE_ADMIN_PASSWORD | The password of that account, 72 bytes at most. XTM One applies it again at every start: change it in .env, then restart, rather than in the interface, where a change lasts until the next restart |
-
Check that
.envholds your own values, not those of.env.sample.grep -E '^(XTM_ONE_(HOST|PORT|EXTERNAL_SCHEME|ADMIN_EMAIL|SECRET_KEY)|PLATFORM_REGISTRATION_TOKEN)=' .envCheck that it workedXTM_ONE_EXTERNAL_SCHEME=https,XTM_ONE_HOST=xtm-one.example.com,XTM_ONE_PORT=443, your administrator's email, and long random values for the secret and the token, notChangeMeWithGeneratedRandomString. -
Let the reverse proxy keep long requests open and stream the chat. An agent's answer can take minutes, and Nginx closes a request after 60 seconds without data by default. Add these lines to the
location /block ofxtm-one.example.comin your proxy configuration, then reload it:proxy_read_timeout 300s; proxy_send_timeout 300s;Keep
client_max_body_sizeat 50 MB or more: knowledge base uploads reach that size. The chat streams its answers as server-sent events, which need three things from the proxy:- HTTP/2 between the browsers and the proxy (
http2 on;in theserverblock). Every open tab of XTM One holds its streams, and over HTTP/1.1 a few tabs use up the connections a browser opens to one host: XTM One then stops loading. - Response buffering off for
/api/, or each answer shows only once it is complete. Nginx follows theX-Accel-Buffering: noheader XTM One sends with its streams. - A read timeout above 15 seconds: a stream with nothing to send writes a keep-alive every 15 seconds. The 300 seconds above cover it.
The server block of Publish the platforms over HTTPS already serves HTTP/2 and turns buffering off. It also forwards WebSockets, which the XTM One Desktop app, the runners and the relays use; the chat does not.
- HTTP/2 between the browsers and the proxy (
-
Tell XTM One which address its reverse proxy reaches it from. Behind a proxy, every request comes from the proxy: until XTM One trusts it, the audit log records the proxy's address for every person, the sign-in rate limit counts everyone as one client, and the agent-to-agent endpoints refuse every request with
403 https required. A proxy on the Docker host reaches the container from the gateway of the stack's network:docker network inspect xtm_default --format '{{(index .IPAM.Config 0).Gateway}}'xtmis theCOMPOSE_PROJECT_NAMEof.env. Write that address asFORWARDED_ALLOW_IPSunder thextm-oneservice ofdocker-compose.override.yml, above the# Pinned versionsline:services: xtm-one: environment: - FORWARDED_ALLOW_IPS=172.18.0.1FORWARDED_ALLOW_IPStakes an address, a network in CIDR form or a comma-separated list, and no host name. For a proxy elsewhere, name the address XTM One sees it from; behind several proxies, list each of them. See Public URL and reverse proxy. -
Apply the changes, then wait until XTM One is ready.
docker compose up -d docker compose exec xtm-one curl -sS http://localhost:4000/api/health/readyCheck that it workedIt prints
{"database":"ok","redis":"ok","s3":"ok","status":"ok"}. The first start creates the tables and the built-in agents: until it ends, the answer reads"status": "starting", with HTTP status 503. A dependency that does not answer turns its own field into an error, such as"s3":"error: bucket not found". The healthcheck of xtm-docker asks/api/health, which answers as soon as the server listens, sohealthyindocker compose pscomes before ready. -
Open
https://xtm-one.example.comand sign in once, then read the last request in the access log of XTM One.docker compose logs --tail 200 xtm-one | grep '"http_request"' | tail -n 1Check that it workedclient_ipis the address of your workstation. The gateway address there means thatFORWARDED_ALLOW_IPSdoes not name the proxy: correct it and restartxtm-one.
Connect a language model
- Sign in at
https://xtm-one.example.comwithXTM_ONE_ADMIN_EMAILandXTM_ONE_ADMIN_PASSWORD. - Open Settings > AI and models > Models, click Add Provider, choose the provider, enter its API key and the models to offer. See Set up the platform in Settings.
- Add the license: Settings > Platform > Enterprise License, or the certificate in
XTM_ONE_ENTERPRISE_LICENSE, which then locks the field. Skip this step when a registered OpenCTI or OpenAEV has the Enterprise Edition.
To keep the provider in the configuration of the deployment instead, set its key as a variable of the xtm-one service: LLM_PROVIDER_<NAME>_API_KEY, where <NAME> is OPENAI, ANTHROPIC, GEMINI, MISTRAL, AZURE_OPENAI, BEDROCK, OPENROUTER, OLLAMA, LITELLM or CUSTOM_OPENAI. XTM One applies it at each start, and Models shows the provider with an Env badge. Language models lists the variables that go with it.
Open Chat and ask "What can you do?". The CTEM Assistant, the default agent of every person, answers in a few seconds. An error that names the provider or the model means the key or the model is wrong.
Marc Dupuis, of IT operations at Grand Meridian Hotels, installed the stack on xtm-one.grand-meridian.example and its sister host names, behind Nginx on the Docker host. The stack's network gateway is 172.18.0.1. He keeps the Anthropic key in the team's secret store and adds it to .env as a named variable, XTM_ONE_ANTHROPIC_API_KEY, then writes docker-compose.override.yml:
services:
xtm-one:
environment:
- FORWARDED_ALLOW_IPS=172.18.0.1
- LLM_PROVIDER_ANTHROPIC_API_KEY=${XTM_ONE_ANTHROPIC_API_KEY}
- LLM_PROVIDER_ANTHROPIC_MODELS=claude-sonnet-5,claude-haiku-4-5-20251001
- DEFAULT_MODEL=claude-sonnet-5
After docker compose up -d, /api/health/ready answers "status":"ok", and Hélène Marchetti, the CISO, signs in with XTM_ONE_ADMIN_EMAIL, helene.marchetti@grand-meridian.example, the admin email of OpenCTI and OpenAEV too. Models shows Anthropic with its Env badge, and the license OpenCTI holds gives XTM One its Enterprise Edition once OpenCTI registers.
How XTM One reads its settings
- Two containers.
xtm-oneserves the interface, the API and the chat;xtm-one-workerruns the background work. Both read the public URL, the secret, the database, the storage and the license, and must have the same values. A variable this page gives for one container only is read by that one. - Read at start. After a change, run
docker compose up -d: Docker Compose recreates the containers whose configuration changed. A value XTM One refuses, such as a malformed list or a negative limit, stops it at start with a message that names the variable. - Variable or screen. Agents, language models, single sign-on and most security options are set in Settings and stored in the database. Where a screen field has a variable, the variable wins when it is set: the field shows it read-only, and a change from the screen is refused.
xtm-docker passes XTM One a fixed list of variables, built from .env:
In .env of xtm-docker | XTM One variable | Containers |
|---|---|---|
XTM_ONE_EXTERNAL_SCHEME, XTM_ONE_HOST, XTM_ONE_PORT | BASE_URL, FRONTEND_URL | Both |
XTM_ONE_ADMIN_EMAIL, XTM_ONE_ADMIN_PASSWORD | ADMIN_EMAIL, ADMIN_PASSWORD | Both |
XTM_ONE_SECRET_KEY | SECRET_KEY | Both |
XTM_ONE_POSTGRES_USER, XTM_ONE_POSTGRES_PASSWORD | DATABASE_URL, on the xtm_one database of pgsql | Both |
MINIO_ROOT_USER, MINIO_ROOT_PASSWORD, XTM_ONE_S3_BUCKET | S3_ACCESS_KEY, S3_SECRET_KEY, S3_BUCKET | Both |
PLATFORM_REGISTRATION_TOKEN | PLATFORM_REGISTRATION_TOKEN | Both |
XTM_ONE_ENTERPRISE_LICENSE | ENTERPRISE_LICENSE | Both |
XTM_ONE_LOG_LEVEL, XTM_ONE_LOG_FORMAT | LOG_LEVEL, LOG_FORMAT | Both |
| Fixed | PLATFORM_MODE=xtm_one, REDIS_URL=redis://redis:6379, S3_ENDPOINT=minio:9000, S3_USE_SSL=false | Both |
| Fixed | OPENCTI_API_URL=http://opencti:8080, OPENAEV_API_URL=http://openaev:8080, OPENCRQ_API_URL=http://opencrq:3002, XTM_AUTH_ACCEPTED_AUDIENCES=http://xtm-one:4000 | xtm-one |
XTM_ONE_CUSTOM_TOOL_SANDBOX, OPENSANDBOX_API_KEY, XTM_ONE_OPENSANDBOX_IMAGES, XTM_ONE_OPENSANDBOX_NETWORK_ALLOW | CUSTOM_TOOL_SANDBOX, OPENSANDBOX_API_KEY, OPENSANDBOX_IMAGES, OPENSANDBOX_NETWORK_ALLOW, with OPENSANDBOX_DOMAIN=opensandbox:8090: see Run code in OpenSandbox | Both |
Any other variable goes in docker-compose.override.yml, under the environment of the service, above the # Pinned versions line: see Change the stack without editing docker-compose.yml.
Secrets and the administrator
| Variable | Default | What to know |
|---|---|---|
SECRET_KEY | Required | Signs the sessions and the tokens XTM One sends, and encrypts the credentials it stores: provider keys, integration secrets, OAuth tokens. Never change it once XTM One has started. Changed or lost, every stored credential becomes unreadable and every session ends, with no way back but the old value |
ADMIN_EMAIL | admin@filigran.io in the module | The administrator account. At every start, XTM One creates it or makes it an active administrator again |
ADMIN_PASSWORD | Required | The password of that account, applied again at every start. At most 72 bytes: a longer value stops the platform |
ADMIN_TOKEN | None | An API key for that account, for automation: it starts with fcp- and has 32 characters or more |
Because the administrator's password follows .env at every start, .env gives control of XTM One: keep it readable by its owner only (chmod 600 .env), out of version control, with a copy in your secret store. Change the password in .env, then restart.
Public URL and reverse proxy
| Variable | Default | What to know |
|---|---|---|
BASE_URL | http://localhost:4000 in the module | The public URL people open. It builds the links of emails and of single sign-on, and it is the issuer of every token XTM One signs for OpenCTI, OpenAEV and OpenCRQ: set the same value on both containers, as xtm-docker does |
FRONTEND_URL | Same as BASE_URL | Where the browser comes back after a single sign-on. Mail clients load the images of XTM One's emails from it, under /email-assets/ |
FORWARDED_ALLOW_IPS | 127.0.0.1 | The proxies XTM One trusts, on xtm-one: an address, a CIDR network or a comma-separated list. It reads the client address from X-Forwarded-For and the scheme from X-Forwarded-Proto only on requests from them |
TRUST_PROXY_HEADERS | false | Trusts the forwarded headers from any peer, and takes the leftmost X-Forwarded-For value, which a client can write. Leave it off and use FORWARDED_ALLOW_IPS |
BASE_PATH, BASE_PATH_MODE | None, auto | Serve XTM One under a path, such as /xtm-one. BASE_URL and FRONTEND_URL then end with the same path |
Without FORWARDED_ALLOW_IPS naming the proxy, XTM One sees every request as plain HTTP from the proxy's address: the audit log records that address for every person, the per-address rate limits of the sign-in and password reset count everyone as one client, and the agent-to-agent endpoints refuse every request with 403 https required. XTM One reads FORWARDED_ALLOW_IPS when it starts: it is not a field of Settings > Access and security. It resolves no host name, and a network must have its host bits at zero (10.42.0.0/16, not 10.42.0.1/16); it logs any other entry at start, and that entry trusts nobody. Behind several proxies, such as a load balancer then an ingress, list each one. * trusts every peer: use it only when nothing but the proxy reaches the container.
Give XTM One its own host name, like the other platforms. Under BASE_PATH, the health endpoints and /metrics stay at the root of the container's port, and the prefix must not start with a path XTM One serves itself, such as /api, /mcp or /xtm: the platform refuses it at start. See the URLs of the reference.
Language models
An administrator can add providers in Settings > AI and models > Models. To keep them in the configuration of the deployment instead, set them on xtm-one: the platform applies them at each start, and the worker reads them from the database.
| Variable | Default | What it sets |
|---|---|---|
LLM_PROVIDER_<NAME>_API_KEY | None | The key of a provider. <NAME> is OPENAI, ANTHROPIC, GEMINI, MISTRAL, AZURE_OPENAI, BEDROCK, OPENROUTER, OLLAMA, LITELLM, CUSTOM_OPENAI or FILIGRAN_GATEWAY. The provider shows an Env badge and cannot be deleted from the screen: remove the variable and restart to remove it |
LLM_PROVIDER_<NAME>_MODELS | None | The models offered, comma-separated. Unset, XTM One leaves the list stored for the provider as it is. A provider with no list chats on its built-in model only while no other provider lists one. FILIGRAN_GATEWAY is the exception: unset while no other provider offers a chat model, XTM One asks the gateway for its models at each start |
LLM_PROVIDER_MODELS_EDITABLE | false | false: the list of the variable is the catalog, rewritten at each start. true: it is a baseline that administrators can curate in Models |
MODELS_ENV_PROVIDING_ONLY | false | true refuses every change to providers from the screen and the API |
DEFAULT_MODEL | The first model configured | The default model of the agents, applied again at each start while a provider offers it |
BYOLLM_ACTIVATED | false | Hands the language models to the administrators: DEFAULT_* values apply once, to an install that has no configuration of its own yet |
For CUSTOM_OPENAI, an endpoint that speaks the OpenAI API, the value is the key, two vertical bars, then the base URL of the endpoint. For FILIGRAN_GATEWAY, the Filigran AI Gateway, the URL comes first, optionally followed by || and the provider it targets, then || and a token; without a token, XTM One signs its calls with its own token.
When LLM_PROVIDER_FILIGRAN_GATEWAY_MODELS is unset and no other provider offers a chat model, XTM One asks the gateway for its chat models at start and uses them as its list. It refreshes that list at every start, even once another provider offers chat models, until an administrator edits it in Models, which LLM_PROVIDER_MODELS_EDITABLE=true or BYOLLM_ACTIVATED=true allows. With either of these, the first listing also needs the gateway to have no list yet. A model the gateway stops listing leaves the list, but the agents and people that chose it keep their choice. If the gateway does not answer within 5 seconds, XTM One keeps the stored list and logs could not list the filigran_gateway models.
When every provider that chats lists no model, Models says so: "The configured LLM providers offer no model. Agentic and LLM-powered platform features are unavailable until one does." For a provider set by its variable, whose models administrators cannot edit, an administrator also reads the variable to set, such as "Set LLM_PROVIDER_OPENAI_MODELS and restart, or set LLM_PROVIDER_MODELS_EDITABLE=true to select its models here."
On a host without internet access, use a model served on your network, through OLLAMA, LITELLM or CUSTOM_OPENAI. The rest of the AI settings, such as image and speech models, are in AI providers.
Edition and AI
| Variable | Default | What it sets |
|---|---|---|
ENTERPRISE_LICENSE | None | The Filigran license certificate, in PEM form, on both containers. It can also be pasted in Settings > Platform > Enterprise License; the variable then locks the field |
PLATFORM_MODE | xtm_one | ai_disabled starts XTM One with AI switched off: its screens and data stay available, and no agent runs. See Run XTM One with AI switched off |
XTM One is in the Enterprise Edition with its own license, or when a registered OpenCTI or OpenAEV has one. A license certificate spans several lines: pasting it in Enterprise License is simpler than a variable.
Links to the other platforms
Connect the modules to each other registers OpenCTI and OpenAEV with XTM One and explains the public and internal URLs. On the side of XTM One:
| Variable | Default | What it sets |
|---|---|---|
PLATFORM_REGISTRATION_TOKEN | None | The secret every platform registers with. Unset, XTM One refuses every registration. The published default of the module's Compose file, xtm-default-registration-token, keeps registered platforms connected but registers no new one, and XTM One then sends the platforms no license certificate. After 10 failed attempts in a minute, a client is refused with HTTP 429 until the minute ends |
OPENCTI_API_URL, OPENAEV_API_URL, OPENCRQ_API_URL | The URL each platform registers with | Where XTM One calls each platform, fetches its signing keys and, for OpenAEV, sends its callbacks. Every link people get stays on the registered public URL. A change applies at the platform's next registration, within 5 minutes |
XTM_AUTH_ACCEPTED_AUDIENCES | None | The URLs the platforms reach XTM One on when they differ from BASE_URL, comma-separated. A platform version that addresses its tokens to that URL is refused unless it is listed |
OPENGRC_API_URL, the former name of OPENCRQ_API_URL, is read until 31 December 2026, with a warning in the logs.
XTM One sends invitations, password resets and announcements of model changes by email. Neither xtm-docker nor the module's Compose file passes it a mail server: until you set SMTP_HOSTNAME, XTM One sends nothing, and writes the link of a password reset in its log instead.
| Variable | Default | What it sets |
|---|---|---|
SMTP_HOSTNAME, SMTP_PORT | None, 587 | The mail relay |
SMTP_USERNAME, SMTP_PASSWORD | None | The account, when the relay asks for one |
SMTP_FROM | SMTP_USERNAME | The sender address |
SMTP_STARTTLS | true | Upgrades the connection with STARTTLS, as port 587 expects. For a relay with TLS from the start, on port 465, set SMTP_USE_TLS=true |
Set them on both containers, and set SMTP_FROM_NAME, the name people see as the sender, to the name of your platform. The example at the end of this page reuses the mail settings of the stack.
Security headers
XTM One sends a Content Security Policy on every page it serves, which tells the browser which scripts, styles and connections the page may use. Set these on xtm-one:
| Variable | Default | What it sets |
|---|---|---|
CONTENT_SECURITY_POLICY_MODE | report-only | report-only blocks nothing: browsers report what the policy would block. enforce blocks it. off sends no policy. Any other value stops the platform |
CONTENT_SECURITY_POLICY_FRAME_ANCESTORS | None | The other sites allowed to show XTM One in a frame once the policy is enforced, such as an intranet portal: https://portal.example.com, comma-separated |
XTM One never sends X-Frame-Options, and your proxy must not add it: it would break the Microsoft Teams tab, the Office add-in and the sites you allow to frame XTM One. Until the policy is enforced, any site can frame XTM One. Once it is, XTM One itself, the sites you list and the registered platforms may frame it; the registered platforms only while PLATFORM_REGISTRATION_TOKEN is a value of your own, and at most 20 of them.
To move to enforce:
- Run in
report-onlyfor a few days of normal use: the chat, reports and decks, settings, and every site that embeds XTM One. - Read Settings > Access and security > Security audit: it lists the violations browsers reported in the last 7 days, by directive. The log of
xtm-onenames each new one once, in a line that starts withCSP violation first seen. Violations that browser extensions cause are counted apart. - Set
CONTENT_SECURITY_POLICY_MODE=enforceand rundocker compose up -d.
curl -sI https://xtm-one.example.com/ | grep -i '^content-security-policy'
The header reads content-security-policy:, without -report-only. To go back, set report-only again: nothing else is stored.
Run code in OpenSandbox
Custom tools, the code interpreter and the checks and services an agent starts in a repository workspace run their code in a sandbox. They are off until an administrator turns them on in Settings > Access and security. CUSTOM_TOOL_SANDBOX on both containers decides where the code runs:
| Value | Where the code runs |
|---|---|
auto | xtm-docker's default, XTM_ONE_CUSTOM_TOOL_SANDBOX=auto. A hardened Docker container when the platform can start one, otherwise a restricted process of the XTM One containers. The checks and services of a repository workspace need OpenSandbox: see Run the repository's checks |
opensandbox | One container per run, started by an OpenSandbox server. Also used by the code interpreter |
xtm-docker ships OpenSandbox as the opensandbox profile of modules/xtm-one.yml, off by default. Its server mounts the socket of the container engine to start those containers, which gives it control of every container of the host. To run it, set in .env:
COMPOSE_PROFILES=opensandbox
XTM_ONE_CUSTOM_TOOL_SANDBOX=opensandbox
Then run docker compose up -d: the opensandbox service starts, and xtm-one and xtm-one-worker are recreated with the new value.
In .env of xtm-docker | XTM One variable | What it sets |
|---|---|---|
OPENSANDBOX_API_KEY | OPENSANDBOX_API_KEY | The key XTM One sends to the server, and the server's own key. init-env.sh draws it; the server does not start without one |
XTM_ONE_OPENSANDBOX_IMAGES | OPENSANDBOX_IMAGES | The image of each language. xtm-docker runs the published xtmone/sandbox-python and xtmone/sandbox-nodejs, at the tags of the XTM One release. They are published for linux/amd64 only |
XTM_ONE_OPENSANDBOX_NETWORK_ALLOW | OPENSANDBOX_NETWORK_ALLOW | The domains the sandboxes may reach. Empty, they reach nothing |
CONTAINER_ENGINE_SOCKET | None | The socket the server mounts, /var/run/docker.sock by default. Under rootless Podman, $XDG_RUNTIME_DIR/podman/podman.sock |
xtm-docker points XTM One to the server at opensandbox:8090. The containers the server starts publish their ports on the host, which XTM One reaches as host.docker.internal. See OpenSandbox in the reference for the other settings.
Install packages in the sandbox through a mirror
When XTM One runs its sandbox on OpenSandbox, the checks and services an agent runs in a workspace (sandbox_run_command, sandbox_start_service) run in containers of their own. By default, npm, Yarn, pip and uv install there only the packages their images hold. To let them install others without opening the internet to those containers, run a read-only mirror of npm and PyPI and name it on both containers:
| Variable | Default | What it sets |
|---|---|---|
SANDBOX_REGISTRY_MIRROR_URL | None | The mirror, such as http://registry-mirror:8080. Its host joins the egress of the command and service containers, on top of OPENSANDBOX_NETWORK_ALLOW, and npm, Yarn, corepack, pip and uv install from its /npm/ and /pypi/simple/ paths. The code interpreter and custom tools never use it. An address that is not http or https, or that holds a user, a password, a query or a fragment, stops XTM One at start |
The module ships a mirror, backend/sandbox/registry-mirror/nginx.conf, for an unprivileged nginx (nginxinc/nginx-unprivileged) with the file mounted as /etc/nginx/nginx.conf, on port 8080. It answers only GET and HEAD on the packages of npm and PyPI and refuses every other path with 403, so no one can publish or sign in through it. It drops the Authorization and Cookie headers, holds no credential, and rewrites the download links of the registries to itself. Its container needs DNS and egress to registry.npmjs.org, pypi.org and files.pythonhosted.org. It resolves them through the Kubernetes DNS, kube-dns.kube-system.svc.cluster.local: elsewhere, change its resolver line to the resolver of your network.
Keep the three registries out of OPENSANDBOX_NETWORK_ALLOW, so that the mirror stays the only way to them. With xtm-docker, add the variable to docker-compose.override.yml:
services:
xtm-one:
environment:
- SANDBOX_REGISTRY_MIRROR_URL=http://registry-mirror:8080
xtm-one-worker:
environment:
- SANDBOX_REGISTRY_MIRROR_URL=http://registry-mirror:8080
Size the platform and the worker
| Variable | Default | What it sets |
|---|---|---|
WEB_WORKERS | 2 | The processes of xtm-one that serve the interface, the API and the chat. Raise it when many people chat at the same time: about twice the CPU cores plus one |
WORKER_CONCURRENCY | 20 | The background jobs each worker container runs at once. Add worker replicas when jobs queue |
MAX_CONCURRENT_RUNS | 10 | The assignment runs in parallel |
DB_POOL_SIZE, DB_MAX_OVERFLOW | 15, 10 | The PostgreSQL connections of each process |
Every process opens its own pools: DB_POOL_SIZE plus DB_MAX_OVERFLOW connections, and up to 10 more for the traces of agent runs, so 35 with the defaults. Count every web process and every worker replica against max_connections of PostgreSQL, which xtm-docker sets to 200 for XTM One, OpenAEV and OpenCRQ together, OpenAEV taking up to 20 and OpenCRQ about 50 at peak. With the defaults, XTM One takes up to 105: 35 for each of its 2 web processes and its worker.
To add worker replicas, set deploy.replicas on xtm-one-worker in docker-compose.override.yml, and count each one in the connections.
Grand Meridian Hotels shows XTM One in its intranet portal, https://portal.grand-meridian.example, and wants invitations to reach new members of the SOC. Marc Dupuis, of IT operations, reuses the mail relay that .env already gives OpenAEV, gives the four-core host one more web process per core, and adds to docker-compose.override.yml:
services:
xtm-one:
environment:
- SMTP_HOSTNAME=${SMTP_HOST}
- SMTP_PORT=${SMTP_PORT}
- SMTP_USERNAME=${SMTP_USERNAME}
- SMTP_PASSWORD=${SMTP_PASSWORD}
- SMTP_FROM=xtm-one@grand-meridian.example
- SMTP_FROM_NAME=XTM One
- CONTENT_SECURITY_POLICY_MODE=enforce
- CONTENT_SECURITY_POLICY_FRAME_ANCESTORS=https://portal.grand-meridian.example
- WEB_WORKERS=4
xtm-one-worker:
environment:
- SMTP_HOSTNAME=${SMTP_HOST}
- SMTP_PORT=${SMTP_PORT}
- SMTP_USERNAME=${SMTP_USERNAME}
- SMTP_PASSWORD=${SMTP_PASSWORD}
- SMTP_FROM=xtm-one@grand-meridian.example
- SMTP_FROM_NAME=XTM One
With 4 web processes and one worker, XTM One takes up to 175 connections, and OpenAEV 20: 195, under the 200 of pgsql. After docker compose up -d, Hélène Marchetti invites Paul Garnier from Administration > Users and groups, and his invitation arrives from XTM One <xtm-one@grand-meridian.example>.
Where the data is
| Data | Where, in xtm-docker |
|---|---|
| Agents, conversations, knowledge base chunks and their vectors, assignments, traces, settings, and the encrypted credentials | The xtm_one database of pgsql, in the pgsqlshareddata volume |
| Uploaded documents, chat attachments, generated reports and decks, large trace payloads | The xtm-one-files bucket of minio, in the s3data volume |
| Queued jobs, the state of running chats, rate limits | Redis, in the redisdata volume. Working state: XTM One rebuilds it |
Back them up with the rest of the stack, together with .env: without the same XTM_ONE_SECRET_KEY, a restored XTM One cannot read the credentials it stores. See Back up and restore.
What's next
- XTM One configuration, every variable with its default.
- Monitor and troubleshoot XTM One, for the metrics and the logs.
- Set up the platform in Settings, for what administrators set on screen.
- Connect the modules to each other.