# CLI

The `benson` command has been the engine binary since version 0.9.0. `benson --help` prints the subcommands and `https://benson.strand3.com`. `benson --version` prints the version from the crate.

| Command | Role |
|---|---|
| `benson serve` | HTTP server. `--config`, `--site-dir`, `--port`, `--development`, `--no-auth`, `--pid-file`. |
| `benson build` | Compile CSS, run the image pipeline, warm the cache. `--site-dir`, `--no-warm`. |
| `benson init` | Scaffold a site. See [init](/init/). |

There is no `mcp` subcommand.

## Environment overlays

Since version 0.12.0, `config.toml` is overlaid by environment variables. The prefix is `BENSON`, then one underscore, then the field path with `__` between nested keys.

| Variable | Overlay |
|---|---|
| `BENSON_TITLE` | `title` |
| `BENSON_BASE_URL` | `base_url` |
| `BENSON_SERVER__BIND_ADDR` | `[server].bind_addr` |
| `BENSON_SERVER__CACHE_DIR` | `[server].cache_dir` |
| `BENSON_GLOBALS__KEY` | `[globals].key` (key lowercased) |
| `BENSON_FORMS__NOTIFY` | `[forms].notify`, comma-separated. Empty clears the list. |

`BENSON_SMTP_PASSWORD` is read when mail is sent. It is not a `config.toml` field. Unprefixed `BIND_ADDR` and `CACHE_DIR`, and names that start `BENSON__`, are ignored. The [0.12.0 changelog](/changelog/) is the rename from those older variables.

