Skip to content
Open Source AI Agent Platform

What a self-hosted open source AI agent platform runs on

A self-hosted agent platform needs a small Linux box, disk for Postgres and a URL the outside world can reach. It does not need a GPU. Kortix, the open-source CompanyOS, runs its whole control plane as one Docker Compose stack, and the agents' own computers are rented by the hour. That is my pick, and I work on Kortix's marketing, so weigh that accordingly.

One Compose workspace, every service

one compose workspace
Source:https://kortix.com/docs/self-host
One Compose workspace, kortix-<instance>, holds every service.frontend | The web app.kortix-api | The REST API at /v1. It relays any /v1/llm request that reaches it to llm-gateway.llm-gateway | The standalone LLM gateway. Caddy sends api.<domain>/v1/llm* here.kortix-migrate | A one-shot job. It migrates the database before kortix-api starts.kortix-updater | Pulls new images once a day, migrates, and rolls the app services.supabase-* | The Supabase distribution, every image pinned by digestcaddy | Domain mode only. Terminates TLS on ports 80 and 443 and routes traffic. It gets a certificate per host with ACME HTTP-01, or one wildcard certificate per base after tls wildcard.cloudflared | Tunnel mode only. Publishes kortix-api through a Cloudflare tunnel.

The self-hosting reference's service table: one Compose workspace holds the web app, the API and the gateway, a one-shot migration, the daily updater, the Supabase set, and the edge you choose.

The machine you are pricing belongs to the model

A self-hosted agent platform is a web application and a database. Ask what it needs and the honest answer is a Linux machine with Docker on it, disk for Postgres, and a URL a sandbox can call back to. Nothing in that sentence involves an accelerator.

The GPU belongs to a different workload that happens to share the words "self-hosting AI". Teams add the two together and budget a rack of cards for a platform that would have run on a laptop. Kortix's self-hosted page keeps them apart: the CLI "installs the web app, the API, the LLM gateway and the database on your server as one Docker Compose stack", and its sessions run on Platinum sandboxes that call back to the instance.

From there the sizing question mostly answers itself. Model access is sold per token by providers who keep their hardware busy. A card you buy is paid for whether an agent is thinking or not. Rent the intelligence, own the records.

What the Compose workspace contains

The self-hosting reference lists one Compose workspace holding every service, and the list is shorter than the name suggests. The application plane is three services. frontend is the web app you log into. kortix-api is the REST API at /v1, and it relays any /v1/llm request that reaches it to llm-gateway. llm-gateway is the standalone LLM gateway, with its own image and memory limit, and it calls the model providers your workspaces connect. The data plane is Supabase: supabase-db for Postgres, supabase-auth for sign-in, supabase-rest for the query layer, supabase-storage for files, and supabase-kong in front of them as their proxy. Two more finish the work. kortix-migrate applies the schema change on each release, and kortix-updater checks once a day, then starts the new services before it stops the old ones.

The edge plane holds only what you chose: caddy terminating TLS when you point a domain at the box, or cloudflared in tunnel mode. Nothing in that list wants an accelerator, and Postgres is the one service whose appetite grows with use.

What actually makes the box bigger

Kortix publishes no CPU or memory floor, so the size follows from what the instance holds rather than from a concurrency target. Four things move it:

  • The Postgres data directory: workspaces, session history, policies, the audit record. It grows with time rather than with headcount.
  • The storage directory beside it, which grows with the files agents keep.
  • The edge, when the box terminates TLS and answers preview hostnames.
  • Disk headroom for the updater, because every release pulls a new image set before the old one stops.

Concurrency looks like it belongs on that list, and it is how a model server gets sized. Sessions do not run on your machine. One isolated sandbox per session. Each session has its own isolated machine and branch, and the machine comes from the sandbox provider you configure: Platinum. Your instance routes to it and records what happened. It does not compute. Thousands of agents in parallel on one config, each on its own cloud computer, and the box in the middle stays about the same size.

The machine classes are ordinary, then. A laptop carries a trial, because the CLI can start the stack against a Cloudflare tunnel, and a server carries a team or a company, with the same Compose workspace on both. Pick the smallest host that holds your data with room to grow, and put the difference into model access.

The model is the only line that could want metal

A model has no fixed price the way a server does. It has a rate per token, and where the tokens come from decides the bill. Kortix's pricing page lists the routes, and only the last one needs hardware.

Model routeWhat you payA GPU of yours
Managed models on creditsbase price plus 5.5%, in creditsno
Your own provider keysthe provider's own invoiceno
ChatGPT subscriptionthe plan you already holdno
Open weights on your hardwarethe machine, busy or idleyes

Managed models run on credits at the provider's base price plus a 5.5% platform fee, with zero data retention at the model provider. Your own key sends usage straight to the provider, where the first $1,000 a month is free before Kortix adds 5%, paid from credits. A connected ChatGPT subscription spends no credits at all. A self-hosted instance carries no managed lineup, so it runs on the two middle rows: your keys, or the subscription you already pay for.

The last row is the one people reach for and rarely need. A card pays off when it stays busy, and agent work arrives in bursts. Between two busy hours sit a queue, a batching decision, a quantization choice and a driver stack that changes under you. Where the weights must not leave your network, running them yourself is a real reason to own the machine. Where the motive is a cheaper month, a per-token rate usually wins, because you pay for thought instead of uptime.

Four things to have before the first boot

  1. A Linux host with Docker and the Compose plugin.
  2. A URL a sandbox can reach: a domain pointed at the box, or a Cloudflare tunnel while you evaluate. Sessions call back to the instance, so a tunnel address that changes on restart breaks them.
  3. A Platinum API key, which the page lists under Requirements.
  4. An admin email for the first account, optional at install and settable later.

You prepare none of the passwords. The CLI generates every port, internal URL, password and signing key, along with the whole docker-compose.yml and .env, and writes them to one instance directory at mode 0600. The updates that follow pull their images without registry credentials. A GitHub connection and a model key are not asked for at this point on purpose; both are set in the dashboard once the stack is up. Backups are just as plain, and the page says what a copy does not cover: "Stop the stack, copy the instance directory and its four Docker volumes, then start it again." Drive folders and session workspaces live at Platinum, so a server backup does not hold them.

One box, and a provider for everything else

Run it on Kortix Cloud, in your VPC, or on your own on-prem network. Self-host is free. The governance travels with the records, wherever the box sits. Session work reaches main through a change request. Merge is default-deny for agents.

The setup walkthrough takes the same four prerequisites through the commands that consume them, the self-hosting decision page weighs the box against the managed cloud, and the pricing page works the credit rates through a few team sizes.

Questions people ask before sizing a box

What hardware do you need to self host AI?

A machine that runs a web app and a database, with disk for both. The GPU people budget for belongs to a model, and most teams rent that access by the token. A Kortix instance is one Compose workspace on a Linux server with Docker, and the guide's quick try runs it on your own machine against a Cloudflare tunnel.

Can you self host an AI agent?

Yes. Two machines are involved and only one is yours: the platform that holds the agent's configuration and record, and the sandbox that carries out the work. Kortix puts the first on your box as one Compose workspace and rents the second from a sandbox provider.

Can I build an AI agent on my own?

Yes. An agent needs instructions, a few tools and somewhere to run, and a single host covers the platform side of that. Kortix installs with one command, and the agents are written in the git repo the instance runs from.

What platforms can I use to build AI agents?

Kortix, self-hosted or on Kortix Cloud, or a framework you wire together yourself. The difference is what arrives in the box already: Postgres, sign-in, a model gateway and an update path inside the Compose workspace, rather than four services you assemble and patch.

Install it on a Linux server and grow from there

Run it on Kortix Cloud, in your VPC, or on your own on-prem network. Self-host is free.