Install Odin on a server.
The Debian package is the supported way to run Odin v4.30.0 as a service. It installs everything, opens a setup page on the machine itself, and keeps your settings and data across upgrades.
Before you start
- A 64-bit (amd64) Debian or Ubuntu machine whose python3 is 3.11 or newer, such as Debian 12 or Ubuntu 24.04.
- A Discord application with a bot token, and its Message Content intent turned on.
- A model: a ChatGPT subscription (signed in through Codex), an API key for an OpenAI-compatible service, or Ollama on your own hardware.
- Network access from that machine to the hosts you want Odin to work on.
Know what you’re installing
- The package gives the odin service account passwordless sudo for every command. You can narrow it in /etc/sudoers.d/99-odin-passwordless.
- The shipped config makes everyone who can reach Odin an admin (permissions.default_tier: admin). Change it before you let anyone else in.
- Odin runs what he is asked to run. Register only hosts you are willing to let him operate.
Install the package
It creates an
odinservice account, a Python environment, a browser for the web tools, an SSH key for reaching your hosts, and a systemd service.Shell curl -LO \ https://github.com/Calmingstorm/Odin/releases/download/v4.30.0/odin_4.30.0_amd64.deb sudo apt install ./odin_4.30.0_amd64.debFinish setup in your browser
A fresh install listens only on the machine itself, and stays in setup until you finish this page. Open
http://127.0.0.1:3000/ui/there, or tunnel to it from your computer. Generate your admin token and copy it somewhere safe: you sign in with it from now on. Add your Discord bot token now or later, and sign in to a ChatGPT subscription with a device code if that’s your model.From your computer ssh -L 3000:127.0.0.1:3000 you@odin-host # then open http://127.0.0.1:3000/ui/ on your own computerChoose a model
Signed in to ChatGPT on the setup page? That’s done. To use an OpenAI-compatible API or Ollama instead, set it up in the web interface under System, LLM Config. You can switch later without a restart.
Give him hosts
Add Odin’s public key,
/opt/odin/.ssh/id_ed25519.pub, to a host’sauthorized_keys. Then add the host under System, Hosts in the web interface. Each host is connection-tested before Odin may use it, and you choose who may reach it under Host Access.Check that it works
The service should be active and stay active, and the bot should connect to Discord without errors. Then ask him something harmless that needs a tool:
You@Odin what’s the uptime and disk usage on this machine?
He runs run_command on localhost and replies with the numbers from uptime and df. Ask him to search the audit log and the call is there.
Shell systemctl status odin journalctl -u odin --since "10 minutes ago" # Default WebUI port: 3000; check the configured binding.Open the web interface to your network (optional)
Set
web.hostto the address you want, confirm the change with your API token, and restart. Put it behind TLS if it leaves your network.Shell # after setting web.host and confirming it with your API token: sudo systemctl restart odin
Choosing a model
Switch providers from the WebUI or API at runtime. In-flight requests complete on the current provider; per-provider health is tracked independently.
- ChatGPT subscription
- Sign in with a device code on the setup page. Odin talks to the model through Codex, within your plan’s limits. With several accounts signed in, he moves to the next when one hits its limit.
- OpenAI-compatible API
- Presets for DeepSeek, GLM/Z.AI, Qwen, DashScope, OpenAI, Moonshot and OpenRouter, or a custom endpoint. Set it up under System, LLM Config; you pay that provider per use.
- Ollama
- Models on your own hardware, found automatically once you add its address under System, LLM Config. It must be on your machine or private network.
Other ways to set it up
Install from source, for development
Use a source checkout for development. Install the declared extras and configure a private local command workspace outside the checkout before starting Odin. Browser tools need one more install step on a source checkout; the package includes them.
git clone https://github.com/Calmingstorm/Odin.git
cd Odin
python3 -m venv .venv
source .venv/bin/activate
pip install -e ".[dev]"
cp .env.example .env
# Edit .env and config.yml.
mkdir -p ~/.local/share/odin-workspace
chmod 0700 ~/.local/share/odin-workspace
# Set tools.local_working_dir to that absolute path in config.yml.
# If using Codex:
python scripts/codex_login.py --device
python -m srcsource .venv/bin/activate
pip install -e ".[browser]"
python -m playwright install chromiumUpgrading
Install the newer package the same way. Your configuration and data are kept, and Odin restarts only if he was running. If the shipped template changed, the package leaves a config.yml.new-<version> next to yours to compare, instead of rewriting it.
The odin command
odin (alias odin-client) is the API client on every install type: it sends a prompt to a running instance (ODIN_URL or --url, ODIN_API_TOKEN or --token) and exits nonzero when execution fails. odin-server [config-file], or python -m src, starts the server; old server-style odin invocations with a config file, -c, --config or --env-file are refused without sending a prompt. It is not a service-control CLI: use systemctl for the packaged service.
Release notes and every package: GitHub releases