Configuration Reference
offrig resolves configuration from three layers (later layers override earlier ones; override the global config path with OFFRIG_CONFIG):
~/.config/offrig/config.toml— User-global Rigs,default_rig, trusted[secrets.*]resolvers, and[shim.routing].<worktree>/offrig.toml— Checked-in repository Environment,[deps],[sync],[resources], and[run]. Strictly sandboxed by the local trust boundary.<worktree>/offrig.local.toml— Gitignored user-local overrides for a single Worktree (trusted for secret resolvers and per-repo Rig selection).
User-global ~/.config/offrig/config.toml
Section titled “User-global ~/.config/offrig/config.toml”default_rig = "homelab"
[rigs.local]provider = "local"idle_minutes = 30allow_host_docker = false
[rigs.homelab]provider = "ssh"host = "dev@build-01.ts.net"socket = "/var/run/docker.sock"idle_minutes = 15allow_host_docker = false
[rigs.daytona]provider = "daytona"api_url = "https://app.daytona.io/api"target = "us"auto_stop_minutes = 15auto_archive_days = 7[rigs.daytona.api_key]env = "DAYTONA_API_KEY"
[rigs.vm]provider = "boat"api_url = "https://boat.dev/api/v1"machine_type = "large" # small | default | large | xlargeno_env = trueidle_minutes = 30[rigs.vm.api_key]env = "BOAT_API_KEY"
[rigs.edge]provider = "cloudflare"url = "https://offrig-gw-edge.example.workers.dev"idle_minutes = 2default_disk_mib = 16384 # 2048..=20480[rigs.edge.token]env = "OFFRIG_CLOUDFLARE_TOKEN"
[rigs.modal]provider = "modal"app = "offrig" # <= 51 charsmodal_environment = "main"runtime = "gvisor" # gvisor | vm (enables dind; forbids gpu)# gpu = ["H100", "A100-80GB"]idle_minutes = 5 # default 5; max 1440 (24h); 0 disables idle stop# [rigs.modal.token_id]# env = "MODAL_TOKEN_ID"# [rigs.modal.token_secret]# env = "MODAL_TOKEN_SECRET"
[rigs.e2b]provider = "e2b"# domain = "e2b.app"# api_url = "https://api.e2b.app"# sandbox_url = "https://sandbox.e2b.app"idle_minutes = 15 # 1..=1440# paused_retention_days = 30 # 1..=36500 (omit for indefinite)[rigs.e2b.api_key]env = "E2B_API_KEY"
[rigs.sprites]provider = "sprites"# api_url = "https://api.sprites.dev"[rigs.sprites.token]env = "SPRITES_TOKEN"
[secrets.NPM_TOKEN]env = "NPM_TOKEN"
[secrets.OP_SECRET]cmd = ["op", "read", "op://Dev/App/token"]
[git]credential_hosts = ["github.com"]
[shim.routing]max_local_concurrent = 2max_load_ratio = 0.75min_free_memory_percent = 20
[update]notify = true
[telemetry]enabled = true # set `false` (or run `offrig telemetry disable`) to opt outusage = trueerrors = trueRepository <worktree>/offrig.toml
Section titled “Repository <worktree>/offrig.toml”[env]# Curated Ubuntu 24.04 by default; optionally set `image` OR `dockerfile` (Docker-backed Providers)packages = ["build-essential", "pkg-config", "libssl-dev"]setup = "rustup component add clippy rustfmt"
[deps]enabled = trueauto_update = false# Optional overrides; auto-detected from Cargo.lock / pnpm-lock.yaml / uv.lock / go.sum when omitted# lockfiles = ["Cargo.lock"]# command = "cargo fetch --locked"
[sync]remote_only = ["node_modules", "/target", ".venv", ".turbo"]include = [] # gitignored paths inside Worktree root (cannot escape root)git = "auto" # auto | full | offgit_max_bytes = 104857600 # 100 MiB defaultconflict = "fail" # fail | overwrite | keep-local
[resources]cpu = 4memory_mib = 8192# disk_mib = 16384# idle_minutes = 15hold_cap_minutes = 60memory_guard = truememory_guard_soft_pct = 90memory_guard_hard_pct = 95memory_guard_soft_min_mib = 512memory_guard_hard_min_mib = 256
[run]docker = "off" # off | dind | host (host requires Rig allow_host_docker = true)ports = ["3000"]Local override <worktree>/offrig.local.toml
Section titled “Local override <worktree>/offrig.local.toml”Add offrig.local.toml to .gitignore to pin a personal Rig or local secret resolver for one repository without affecting teammates:
rig = "homelab"
[git]credential_hosts = ["github.com"]
[secrets.STRIPE_TEST_KEY]file = "~/.secrets/stripe-test.key"