Aller au contenu
Docs

Ce guide est disponible uniquement en anglais.

Self-hosting

Run Vixi on your own server with Docker Compose and your own model key.

Before you start

You need a Linux server, or a Mac for testing, with Docker and Docker Compose 2.24 or later. Use a dedicated server if you can. Anyone who controls Docker on the server can read its data and secrets.

UseCPUMemoryFree disk
Try the core services2 cores8 GB40 GB
One person, with files and browser tools4 cores16 GB80 GB
A small group8 cores32 GB160 GB or more

These sizes are planning estimates, not tested limits. Busy workspaces, large files, backups and local models need more. If you use Ollama, add the memory, storage and GPU your chosen model needs.

Install

Run one command. The script asks for a domain and a model key, and you can skip either:

Shell
curl -fsSL https://raw.githubusercontent.com/AradHajari/vixi/v0.2.1/deploy/install.sh | bash

You can download and read the script before you run it. It checks Docker, downloads the release to ~/vixi, generates new secrets and saves them in .env. Then it downloads the images, starts Vixi and checks that it works. If you run it again, it keeps your existing .env. It doesn't install Docker or change your firewall.

To install without prompts, for example with a domain:

Shell
curl -fsSL https://raw.githubusercontent.com/AradHajari/vixi/v0.2.1/deploy/install.sh | bash -s -- --non-interactive --domain vixi.example.com

Add --profiles none to install only the core services. By default, the script adds the files and browser profiles.

Create the owner account

  1. When it finishes, the installer prints a link such as http://localhost:8080/#setup=…. Open it. The part after #setup= is your SETUP_TOKEN.
  2. The setup page reads the token and removes it from the address bar. You can also paste the token into the page.
  3. Create the owner account, choose who can sign up and, if you want, add a model key.
SettingWho can create an account
single-userNobody after the owner
invite-onlyPeople the owner invites. If email is set up, they must prove they own the address.
openAnyone who can reach the server

What Compose runs

Docker Compose services and networksCaddy is the public entry point and reaches web, control and edge. Control and edge use Redis, and control and the model proxy use Postgres, on an internal data network. Only the Docker proxy has the Docker socket. Workspaces use a separate network and reach selected routes through the gateway. The optional file service has no internet access.Your browser or appFront networkCaddyWebEdgeControlDocker network, internalDocker proxyOnly service withthe Docker socketData network, internalDataPostgresRedisApp networkGatewayModelsLiteLLMSandbox networkWorkspacesOne container per personFiles network, internalFilesOptional

Dashed boxes show Docker networks. Some services are on more than one. By default, only Caddy opens a port on the server. Internal networks have no direct internet access. Workspaces can use the internet and can reach only selected Vixi routes through the gateway.

ServiceJob
caddyReceives web traffic and handles HTTPS if you set a domain
webServes the web app
controlRuns accounts, setup, the vault and workspaces, and updates its database when it starts
edgeKeeps live connections open
docker-proxyAllows a short list of Docker actions and installs each workspace's nftables firewall. Control never has direct access to the Docker socket.
canaryInternal probe target checked by doctor and every workspace start to prove sandboxes cannot reach internal services
gatewayGives workspaces access to selected control, edge, model and file routes
model-proxyRuns LiteLLM and connects to your model provider
postgresStores data in Postgres 16 with pgvector
redisPasses messages between services and tracks online devices

There are three optional profiles:

  • files adds document and media tools. Its image is about 4 GB.
  • browser prepares the read-only browser and developer tools volumes.
  • ollama adds a local model server.

The main settings come from .env. Compose sets the fixed values itself, including SELF_HOSTED=true, EDITION=self-hosted, INSTANCE_DRIVER=container, BLOB_DRIVER=fs and PAYMENTS_PROCESSOR=none.

SettingPurpose
PUBLIC_URL, VIXI_DOMAINPublic address and optional domain
SETUP_TOKENLets you create the owner account
JWT_PRIVATE_KEY, JWT_PUBLIC_KEYSSign and check access tokens. Control gets only the private key. Edge gets only the public key.
JWT_SECRET, EDGE_SHARED_SECRETSecrets used by the server
VAULT_MASTER_KEYProtects saved secrets. Keep a secure backup.
LITELLM_MASTER_KEY, LITELLM_SALT_KEYProtect the model proxy and the model settings it stores
VIXI_HTTP_PORT, VIXI_TRUSTED_PROXIESLocal port (default 8080), and the proxies in front of Caddy whose visitor addresses Vixi trusts
RESEND_API_KEY, EMAIL_FROMOptional Resend credentials for magic sign-in codes and email invites
SANDBOX_BLOCKOptional extra IPs or CIDRs (such as your server's public IP) blocked from workspaces

The installer generates these secrets. Don't commit .env or share it. The configuration reference lists every setting.

Model keys

You need one model provider. Enter its key during installation, on the setup page or later in the owner's server settings. If you enter a key in the app, control stores it in the encrypted vault and applies it to LiteLLM, and checks it again each time control starts. A key saved in the app is used instead of the one in .env. The provider you saved last answers chats.

You can also set one of these in .env:

.env
OPENAI_API_KEY=your-openai-key

Replace the example value with your key. Your provider account is charged for usage.

Then restart the services:

Shell
cd ~/vixi && ./vixi-ctl.sh up

Image generation and meaning-based memory search also need an OpenAI or Gemini key. Models explains which provider answers and the default model of each.

Domain and HTTPS

Without a domain, Vixi is available at http://localhost:8080, and only from that computer. To make it public:

  1. Point the domain's DNS record to your server.
  2. Allow TCP ports 80 and 443. UDP port 443 is optional and is used for HTTP/3.
  3. Install with --domain vixi.example.com.

Caddy gets and renews the HTTPS certificate. If another reverse proxy (Nginx, Traefik, Cloudflare Tunnel) handles HTTPS, install with --public-url https://vixi.example.com, set VIXI_TRUSTED_PROXIES to your proxy's CIDR, and forward HTTP plus WebSocket upgrades (/ws/*, /edge/*) to 127.0.0.1:8080. Caddy then listens only on 127.0.0.1. Don't serve Vixi over the internet without HTTPS.

These options apply to a new .env. Running the installer again doesn't change an existing one.

Connected apps and OAuth

OAuth is optional. Email and password sign-in works without it. Eight common providers are wired directly in docker-compose.yml: GOOGLE, MICROSOFT, GITHUB, SLACK, NOTION, LINEAR, SPOTIFY and DROPBOX. Set the provider's redirect URL to:

Text
https://vixi.example.com/v1/oauth/callback/<provider>
https://vixi.example.com/v1/auth/oauth/google/callback   # also needed for Google sign-in

Add the client ID and secret to .env and run ./vixi-ctl.sh up:

.env
GOOGLE_CLIENT_ID=
GOOGLE_CLIENT_SECRET=
MICROSOFT_CLIENT_ID=
MICROSOFT_CLIENT_SECRET=
GITHUB_CLIENT_ID=
GITHUB_CLIENT_SECRET=
SLACK_CLIENT_ID=
SLACK_CLIENT_SECRET=

Control also supports other OAuth providers, such as GitLab, Atlassian, Figma, Discord, HubSpot, Salesforce and Xero. Pass their settings with an override file. Providers can limit permissions or require a review. To send magic sign-in codes or invites by email, set RESEND_API_KEY and EMAIL_FROM.

Coolify and Dokploy

The deployment kit's templates folder has guides for Coolify and Dokploy, which use the same Compose file. Railway can't run Vixi's workspaces because it doesn't give apps access to Docker. On a computer with Docker, this command creates the settings without starting Vixi:

Shell
curl -fsSL https://raw.githubusercontent.com/AradHajari/vixi/v0.2.1/deploy/install.sh | bash -s -- --env-only --public-url https://vixi.example.com

Add the values from .env to your platform as secrets. Vixi starts a container for each person, so the server needs a Docker socket for the policy proxy. A platform without one can't run workspaces by itself.

Isolation and gVisor

The default setup reduces the risk with separate networks, limited container permissions and the Docker policy proxy. The proxy needs the Docker socket and is a trusted part of the server. To block your server's public address too, add it to SANDBOX_BLOCK. Run ./vixi-ctl.sh doctor to test isolation on your server. Use a server with no cloud role, or limit access to its metadata. The security guide explains what is blocked and what isn't. Open sign-up lets strangers run code on your server. Avoid it unless you have planned for that risk.

On Linux, you can use gVisor (runsc). It puts another layer between a workspace and the server's kernel. It needs Linux 5.16 or newer. It is optional, may affect speed and compatibility, and doesn't remove all risk.

  1. Install gVisor and set up runsc as a Docker runtime. Make it Docker's default runtime if you want it to run workspaces. The --gvisor option doesn't do this for you.
  2. Use --gvisor when you first install Vixi. This option adjusts Vixi's network and process-limit settings for gVisor. Workspaces then use Docker's default bridge, so don't run other containers there.
  3. Start a chat. Then use docker inspect to check that the workspace container uses runsc.

Changing Docker's default runtime affects other new containers on the server, so test this first. The gVisor guide has the full steps, including for an existing install.

Back up and upgrade

Run these commands from the install folder:

CommandWhat it does
./vixi-ctl.sh upStarts all services
./vixi-ctl.sh downStops all services and workspaces, and keeps the data
./vixi-ctl.sh statusShows what is running
./vixi-ctl.sh logs controlFollows one service's logs
./vixi-ctl.sh backupSaves both databases, files, people's workspaces and .env
./vixi-ctl.sh upgradeMakes a backup, downloads the release again and restarts. Add a version to change releases.
./vixi-ctl.sh doctorChecks Docker, settings, signing keys, service health and live sandbox firewall isolation

Vixi stops briefly during a backup so the saved data matches. An upgrade stops if its backup fails. Control updates its database when the new version starts.

Day-to-day commands, upgrades and fixes for common problems are in Operations and troubleshooting. For apps and other ways to get Vixi, see Apps and downloads.