mirror of
https://github.com/fabro-sh/fabro.git
synced 2026-09-15 23:32:46 +00:00
Add a server-side web.enabled toggle and CLI overrides so Fabro can run with API and health only while disabling the embedded SPA, browser auth routes, and web-only helper endpoints.
240 lines
8.5 KiB
Text
240 lines
8.5 KiB
Text
---
|
|
title: "Server Configuration"
|
|
description: "Server-owned settings.toml sections, CLI overrides, and environment variables"
|
|
---
|
|
|
|
## Config file
|
|
|
|
`fabro server start` reads `~/.fabro/settings.toml` by default. This is the same file schema used by the CLI.
|
|
|
|
On a same-machine setup, the CLI and server share one `settings.toml`. On a remote deployment, the server machine has its own `settings.toml`, and the client machine keeps a separate local `settings.toml` for CLI-only values such as `[server].target`.
|
|
|
|
<Note>
|
|
Legacy `server.toml`, `user.toml`, and `cli.toml` are ignored with a warning. Rename them to `settings.toml`.
|
|
</Note>
|
|
|
|
### Which sections are server-owned
|
|
|
|
| Scope | Examples |
|
|
|---|---|
|
|
| Server-owned | `storage_dir`, `max_concurrent_runs`, `[web]`, `[api]`, `[features]` |
|
|
| Shared with CLI and workflow defaults | `[llm]`, `[log]`, `[git]`, `[setup]`, `[sandbox]`, `[checkpoint]`, `[vars]`, `[pull_request]` |
|
|
|
|
The CLI-only `[server]` section still belongs in the client machine's `settings.toml`. It tells CLI commands where to find a server. The server process does not read `[server].target` for its own binding or routing.
|
|
|
|
### Full reference
|
|
|
|
```toml title="settings.toml"
|
|
# Maximum concurrent workflow runs (default: 5)
|
|
max_concurrent_runs = 8
|
|
|
|
# Override the default data directory (default: ~/.fabro)
|
|
data_dir = "/var/lib/fabro"
|
|
|
|
[api]
|
|
base_url = "https://fabro.example.com/api/v1"
|
|
|
|
[api.tls]
|
|
cert = "/etc/fabro/tls/cert.pem"
|
|
key = "/etc/fabro/tls/key.pem"
|
|
ca = "/etc/fabro/tls/ca.pem"
|
|
|
|
# Authentication strategies (array of Jwt or Mtls)
|
|
[[api.authentication_strategies]]
|
|
type = "Jwt"
|
|
|
|
[web]
|
|
enabled = true
|
|
url = "https://fabro-web.example.com"
|
|
|
|
[web.auth]
|
|
provider = "Github"
|
|
allowed_usernames = ["alice", "bob"]
|
|
|
|
[git]
|
|
provider = "Github"
|
|
app_id = "123456"
|
|
client_id = "Iv1.abc123"
|
|
|
|
[log]
|
|
level = "info"
|
|
|
|
[git.author]
|
|
name = "fabro-bot"
|
|
email = "fabro-bot@company.com"
|
|
|
|
[git.webhooks]
|
|
strategy = "tailscale_funnel"
|
|
|
|
# Run defaults — applied to every run unless overridden by workflow/project config
|
|
[llm]
|
|
model = "claude-sonnet-4-5"
|
|
provider = "anthropic"
|
|
|
|
[llm.fallbacks]
|
|
anthropic = ["gemini", "openai"]
|
|
|
|
[setup]
|
|
commands = ["npm install"]
|
|
timeout_ms = 120000
|
|
|
|
[sandbox]
|
|
provider = "daytona"
|
|
|
|
[sandbox.daytona]
|
|
auto_stop_interval = 60
|
|
|
|
[sandbox.daytona.labels]
|
|
team = "platform"
|
|
|
|
[features]
|
|
retros = true
|
|
|
|
[checkpoint]
|
|
exclude_globs = ["**/node_modules/**", "**/.cache/**"]
|
|
|
|
[vars]
|
|
default_branch = "main"
|
|
```
|
|
|
|
### CLI overrides
|
|
|
|
Several `settings.toml` settings can be overridden via `fabro server start` flags:
|
|
|
|
| Flag | Default | Description |
|
|
|---|---|---|
|
|
| `--bind` | `~/.fabro/fabro.sock` | Address to bind: `IP` or `IP:port` for TCP, or a path for Unix socket |
|
|
| `--web` | enabled | Enable the embedded web UI, browser auth routes, and web-only helper endpoints |
|
|
| `--no-web` | disabled | Disable the embedded web UI, browser auth routes, and web-only helper endpoints |
|
|
| `--foreground` | — | Run in the foreground instead of daemonizing |
|
|
| `--model` | — | Override default LLM model |
|
|
| `--provider` | — | Override default LLM provider |
|
|
| `--sandbox` | — | Override default sandbox provider |
|
|
| `--max-concurrent-runs` | `5` | Maximum concurrent run executions |
|
|
| `--config` | `~/.fabro/settings.toml` | Path to server config file |
|
|
| `--dry-run` | — | Execute with simulated LLM backend |
|
|
|
|
CLI flags take precedence over `settings.toml` values. See [Run Configuration — Precedence](/execution/run-configuration#precedence) for the full resolution order.
|
|
|
|
### `[web]` section
|
|
|
|
Control the embedded SPA and browser-oriented routes.
|
|
|
|
| Key | Description | Default |
|
|
|---|---|---|
|
|
| `enabled` | Serve the embedded SPA, `/auth/*`, and the web-only helper endpoints under `/api/v1` | `true` |
|
|
| `url` | External web UI URL used for OAuth redirects | `http://localhost:3000` |
|
|
|
|
When `enabled = false`, the server still exposes the machine API and `/health`, but `/`, `/auth/*`, SPA client routes, `/api/v1/auth/me`, `/api/v1/setup/*`, and `/api/v1/demo/toggle` all return `404`.
|
|
|
|
### Run defaults
|
|
|
|
The `[llm]`, `[setup]`, `[sandbox]`, `[checkpoint]`, and `[vars]` sections in `settings.toml` act as defaults for every run.
|
|
|
|
On a same-machine setup, `settings.toml` is the shared machine-default layer under `workflow.toml` / `run.toml` and `fabro.toml`.
|
|
|
|
On a remote setup, the client bundles workflow, project, and user config into the run manifest. The server then layers those bundled client configs over its own local defaults for run-shaped fields. Server-owned values like `storage_dir`, `[api]`, `[web]`, `[features]`, and `max_concurrent_runs` always come from the server machine's own `settings.toml` or `fabro server start` flags.
|
|
|
|
For `[vars]`, Daytona labels, and checkpoint exclude globs, values are **merged** and the more specific layer wins on key collisions. All other fields use "first non-empty wins" precedence.
|
|
|
|
### `[log]` section
|
|
|
|
Configure the default log level without environment variables. Precedence: `FABRO_LOG` env var > `--debug` flag > `[log]` level > `"info"`.
|
|
|
|
| Key | Description | Default |
|
|
|---|---|---|
|
|
| `level` | Log level: `error`, `warn`, `info`, `debug`, `trace` | `"info"` |
|
|
|
|
### `[git.author]` section
|
|
|
|
Customize the git author identity used for checkpoint commits. When not set, defaults to `fabro` / `fabro@local`.
|
|
|
|
| Key | Description | Default |
|
|
|---|---|---|
|
|
| `name` | Git author name | `"fabro"` |
|
|
| `email` | Git author email | `"fabro@local"` |
|
|
|
|
On same-machine setups, the CLI and server read the same `[git.author]`. On remote setups, the server uses its local `settings.toml`.
|
|
|
|
### `[git.webhooks]` section
|
|
|
|
Enable automatic GitHub webhook delivery via Tailscale funnel. When configured, `fabro server start` binds a local HTTP listener, exposes it through `tailscale funnel`, and updates the GitHub App's webhook URL on startup. Incoming webhooks are verified with HMAC-SHA256.
|
|
|
|
| Key | Description | Values |
|
|
|---|---|---|
|
|
| `strategy` | Webhook delivery method | `"tailscale_funnel"` |
|
|
|
|
Requires a configured GitHub App (`[git]` section with `app_id` and `client_id`) and the `GITHUB_APP_WEBHOOK_SECRET` environment variable.
|
|
|
|
### `[checkpoint]` section
|
|
|
|
Configure checkpoint behavior for all runs.
|
|
|
|
| Key | Description |
|
|
|---|---|
|
|
| `exclude_globs` | Glob patterns for files to exclude from checkpoint commits (for example, `["**/node_modules/**"]`) |
|
|
|
|
Exclude globs from `settings.toml` and run configs are merged (union, deduplicated). See [Run Configuration — Checkpoint](/execution/run-configuration#checkpoint) for per-run configuration.
|
|
|
|
### `[features]` section
|
|
|
|
Toggle experimental or opt-in features. All features default to `false`.
|
|
|
|
| Key | Description |
|
|
|---|---|
|
|
| `retros` | Enable automatic [retro](/execution/retros) generation after workflow runs (experimental) |
|
|
| `session_sandboxes` | Enable session sandboxes in the web UI |
|
|
|
|
The same `[features]` section can be set in `fabro.toml` (project-level) to enable features per-project.
|
|
|
|
## Secrets and environment variables
|
|
|
|
Fabro stores server-managed credentials in `<data_dir>/secrets.json` and also honors relevant environment variables from the server process environment as a fallback. Fabro no longer auto-loads `.env` files. Provider API keys are required for the models you want to use; everything else is optional.
|
|
|
|
### LLM provider keys
|
|
|
|
| Variable | Provider |
|
|
|---|---|
|
|
| `ANTHROPIC_API_KEY` | Anthropic (Claude) |
|
|
| `OPENAI_API_KEY` | OpenAI (GPT) |
|
|
| `GEMINI_API_KEY` or `GOOGLE_API_KEY` | Google (Gemini) |
|
|
| `KIMI_API_KEY` | Kimi |
|
|
| `ZAI_API_KEY` | Zai (GLM) |
|
|
| `MINIMAX_API_KEY` | Minimax |
|
|
| `INCEPTION_API_KEY` | Inception (Mercury) |
|
|
|
|
### Sandbox and tools
|
|
|
|
| Variable | Description |
|
|
|---|---|
|
|
| `DAYTONA_API_KEY` | Daytona cloud sandbox API key |
|
|
| `BRAVE_SEARCH_API_KEY` | Brave Search API key (for the `web_search` tool) |
|
|
|
|
### Server authentication
|
|
|
|
| Variable | Description |
|
|
|---|---|
|
|
| `FABRO_JWT_PRIVATE_KEY` | Ed25519 private key (base64-encoded PEM) for JWT signing |
|
|
| `FABRO_JWT_PUBLIC_KEY` | Ed25519 public key (base64-encoded PEM) for JWT verification |
|
|
| `SESSION_SECRET` | Session encryption secret (64-character hex string) |
|
|
|
|
### GitHub App (optional)
|
|
|
|
| Variable | Description |
|
|
|---|---|
|
|
| `GITHUB_APP_CLIENT_SECRET` | GitHub App client secret |
|
|
| `GITHUB_APP_WEBHOOK_SECRET` | GitHub App webhook secret |
|
|
| `GITHUB_APP_PRIVATE_KEY` | GitHub App private key (base64-encoded) |
|
|
|
|
### Slack integration (optional)
|
|
|
|
| Variable | Description |
|
|
|---|---|
|
|
| `FABRO_SLACK_APP_TOKEN` | Slack App-level token |
|
|
| `FABRO_SLACK_BOT_TOKEN` | Slack Bot token |
|
|
|
|
### Logging
|
|
|
|
| Variable | Default | Description |
|
|
|---|---|---|
|
|
| `FABRO_LOG` | `info` | Log level: `error`, `warn`, `info`, `debug` |
|