CLI
Commands for starting and managing Strait server components.
serve
Start Strait server components.
| Flag | Type | Default | Description |
|---|---|---|---|
| --mode | string | all | Component mode (api, worker, all) |
strait serve --mode allRunning the strait binary with no subcommand is equivalent to running strait serve.
server start
Equivalent to the serve command.
| Flag | Type | Default | Description |
|---|---|---|---|
| --mode | string | all | Component mode (api, worker, all) |
strait server start --mode apiServer Modes
Strait can be run in different modes to allow for independent scaling of components:
- api: Handles HTTP requests, API endpoints, and webhooks. Use this mode for scaling the web-facing layer.
- worker: Executes jobs and workflows. Use this mode for scaling the processing power of the system.
- all: Runs both API and worker components in a single process. This is ideal for local development or small-scale deployments.
In production, it is recommended to run api and worker modes separately to ensure that heavy job execution does not impact API responsiveness.
Was this page helpful?