Fabric is configured via CLI flags, environment variables, or a .env file. Environment variables take precedence over .env file values.
| Flag | Env Var | Default | Description |
|---|
--host | HOST | 127.0.0.1 | HTTP bind address |
--port | PORT | 3001 | HTTP port |
--grpc-port | GRPC_PORT | 3002 | gRPC port |
--database-url | DATABASE_URL | — | Postgres connection string |
| — | RUST_LOG | info | Log level filter (tracing) |
| Flag | Env Var | Default | Description |
|---|
--jwt-secret | JWT_SECRET | — | Supabase JWT HS256 secret |
--fabric-env | FABRIC_ENV | development | Set to production to disable dev headers |
| Flag | Env Var | Default | Description |
|---|
--openai-api-key | OPENAI_API_KEY | — | Enables OpenAI provider |
| — | OPENAI_BASE_URL | https://api.openai.com/v1 | Custom OpenAI-compatible endpoint |
--anthropic-api-key | ANTHROPIC_API_KEY | — | Enables Anthropic provider |
--ollama-enabled | OLLAMA_ENABLED | false | Enable Ollama provider |
--ollama-url | OLLAMA_URL | http://localhost:11434 | Ollama server URL |
| — | WHISPER_URL | — | Whisper server URL |
--comfyui-enabled | COMFYUI_ENABLED | false | Enable ComfyUI provider |
--comfyui-url | COMFYUI_URL | http://localhost:8188 | ComfyUI server URL |
--onnx-model-dir | ONNX_MODEL_DIR | — | ONNX model directory |
--candle-enabled | CANDLE_ENABLED | false | Enable Candle provider |
| Flag | Env Var | Default | Description |
|---|
--worker-id | WORKER_ID | random UUID | Unique worker identity |
--concurrency | WORKER_CONCURRENCY | 4 | Max steps to claim per poll cycle |
--poll-interval | WORKER_POLL_INTERVAL | 500 | Poll interval in milliseconds |
--lease-seconds | WORKER_LEASE_SECONDS | 30 | Lease TTL before auto-expiry |
--max-retries | WORKER_MAX_RETRIES | 3 | Max retry attempts per step |
--database-url | DATABASE_URL | — | Postgres connection string |
| — | RUST_LOG | info | Log level filter |
| Profile | Services |
|---|
default | Postgres |
ai | Postgres + Ollama + Whisper + ComfyUI |
full | Everything |
| Command | Description |
|---|
just infra-up | Full stack (Postgres + Ollama + Whisper + ComfyUI) |
just infra-up-db | Postgres only |
just infra-up-ai | Postgres + AI services |
just infra-down | Stop everything |
just infra-reset | Fresh start (delete volumes) |
just infra-psql | Open psql shell |
just infra-migrate | Re-apply migrations |
just infra-smoke-test | Verify migrations on clean DB |
just ollama-pull <model> | Pull an Ollama model |
just ollama-list | List available Ollama models |
| Command | Description |
|---|
just run | Start control plane |
just executor | Start execution plane worker |
just fmt | Format all code |
just clippy | Lint with -D warnings |
just test | Run all tests |
just doc | Build documentation |
just ci | All of the above |
DATABASE_URL=postgres://fabric:fabric@localhost:5432/fabric
JWT_SECRET=your-supabase-jwt-secret
ANTHROPIC_API_KEY=sk-ant-...
OLLAMA_URL=http://localhost:11434
WHISPER_URL=http://localhost:8080