CLI Reference¶
Complete reference for all otto command-line options.
Global options¶
These options are available on every otto command:
Option |
Env var |
Default |
Description |
|---|---|---|---|
|
|
(required) |
Lab name(s), comma-separated |
|
|
current dir |
Output directory for logs and artifacts |
|
|
|
Use field or debug products |
|
|
|
Number of days to retain logs |
|
|
|
Logging level |
|
|
|
Rich formatting in log files |
|
|
Verbose console output |
|
|
|
Preview without running commands |
|
|
current user |
Check reservations as USERNAME instead of the current user |
|
|
|
Bypass the reservation check entirely (emergency use only) |
|
|
List available lab names and exit |
||
|
List host IDs in the loaded lab and exit |
||
|
Print full lab details and exit |
||
|
Delete the shell-completion cache file and exit |
||
|
Show version and exit |
||
|
Install shell completion and exit |
||
|
Print shell completion script and exit |
||
|
Show help and exit |
Important
Option placement matters. Global options (including --lab/-l) must
appear before the subcommand — they are parsed by the top-level otto
command, not the subcommand. For example:
✅
otto --lab my_lab run deploy --debug❌
otto run deploy --debug --lab my_lab
The same rule applies to --dry-run, --xdir, --log-level, and every
other option listed above. Subcommand-specific options (like --firmware
for a suite, or --interval for monitor) go after the subcommand.
otto run¶
Run registered instructions.
otto run <instruction> [OPTIONS]
otto run --list-instructions
Option |
Description |
|---|---|
|
List all available instructions and exit |
Each instruction defines its own options via Typer annotations. Use
otto run <instruction> --help to see them.
otto test¶
Run registered test suites.
otto test [PARENT OPTIONS] <Suite> [SUITE OPTIONS]
otto test --list-suites
Parent options (before the suite name)¶
Option |
Default |
Description |
|---|---|---|
|
List test suites with run syntax and exit |
|
|
|
Pytest marker expression (e.g. |
|
|
Repeat each test N times in one setup/teardown cycle |
|
|
Repeat tests for SECONDS in one setup/teardown cycle |
|
|
Minimum per-test pass rate percent in stability mode (0-100) |
|
auto |
JUnit XML output path |
|
off |
Collect gcov coverage from remotes after the run |
|
|
Override coverage destination (implies |
|
off |
Allow |
|
on |
Delete |
|
off |
Generate an HTML coverage report after the run (implies |
|
|
Override HTML report destination (implies |
|
off |
Allow |
|
|
Title shown in the HTML report header (with |
|
off |
Collect host performance metrics for the entire run |
|
|
Sampling interval for |
|
|
Override monitor data destination ( |
|
all hosts |
Regex restricting which hosts |
Each suite also defines its own options via its Options dataclass.
Use otto test <Suite> --help to see them.
otto host¶
Run commands, transfer files, and log in to lab hosts.
otto host <HOST_ID> run <COMMANDS...>
otto host <HOST_ID> put <SRC...> <DEST>
otto host <HOST_ID> get <SRC...> <DEST>
otto host <HOST_ID> login
otto host --list-hosts
Subcommands¶
Subcommand |
Description |
|---|---|
|
Execute one or more commands on the host |
|
Upload local files to the host |
|
Download files from the host |
|
Open an interactive shell session on the host |
Host-level options¶
Option |
Description |
|---|---|
|
Host ID to operate on (see |
|
Route through an intermediate SSH hop host |
|
Override the terminal protocol for this session |
|
Override the file transfer protocol for this session |
|
List all available host IDs and exit |
otto monitor¶
Launch the interactive performance dashboard.
otto monitor [OPTIONS]
Option |
Default |
Description |
|---|---|---|
|
all hosts |
Regex matched against host IDs via |
|
|
Collection interval (minimum 1.0) |
|
Load historical data from |
|
|
Persist live data to SQLite for later viewing |
Docker container hosts are excluded from the default monitored fleet.
otto cov¶
Generate multi-tier HTML coverage reports from otto test --cov output
directories. This is the report half of the coverage workflow — the
collect half is otto test --cov (see below). For the full
walkthrough, prerequisites (lcov/gcov), and tier recipes, see the
coverage guide.
otto cov report <OUTPUT_DIR...> [OPTIONS]
report is currently the only otto cov subcommand.
Arguments¶
Argument |
Description |
|---|---|
|
One or more |
Options¶
Option |
Default |
Description |
|---|---|---|
|
|
Directory for the generated HTML report ( |
|
|
Title shown in the HTML report header |
|
|
Add a coverage tier; repeatable. See tier rules below. |
Tiers¶
A tier is a named layer of coverage data. --tier is repeatable, and
the order of flags is the precedence order — the first tier is
highest precedence and wins row coloring on the annotated source view.
--tier system(no path) — the implicit tier built by merging the suppliedOUTPUT_DIR.gcdafiles withlcov. Only thesystemtier may omit a path.--tier NAME=PATH— any other tier;PATHmust be a pre-existing lcov-format.infotracefile. A non-systemtier without a path is rejected.Duplicate tier names are rejected.
If no
--tierflag is given, the report defaults to a singlesystemtier.
Examples¶
otto cov report runs/2026-05-16_T1200/ --report ./report
otto cov report run_a/ run_b/ run_c/ --report ./combined
otto cov report runs/ --tier unit=unit.info --tier system --tier manual=manual.info
On success, otto logs the overall coverage percentage, the file count,
and the path to index.html. If no valid coverage data is found in the
supplied directories, the command logs an error and exits non-zero.
Collecting coverage (otto test --cov)¶
otto cov only generates reports — it consumes cov/ directories
produced by a prior otto test run. Collect coverage with the --cov
family of options on otto test:
Option |
Description |
|---|---|
|
Fetch |
|
Write coverage artifacts to an explicit directory (implies |
|
Allow |
|
Delete stale |
|
Also render the HTML report inline after the run (implies |
|
Explicit destination for the inline HTML report (implies |
See the otto test section above for the full option
table, and the coverage guide for end-to-end examples.
otto docker¶
Build images and orchestrate compose stacks on docker-capable lab hosts.
otto docker build [--repo NAME] [--on HOST] [--rebuild] [<IMAGE>...]
otto docker up [--repo NAME] [--on HOST] [--no-build]
otto docker down [--repo NAME] [--on HOST]
otto docker ps [--on HOST]
Docker subcommands¶
Subcommand |
Description |
|---|---|
|
Build container images |
|
Bring compose stacks up |
|
Tear compose stacks down |
|
List running containers on docker-capable hosts |
Docker options¶
Option |
Applies to |
Description |
|---|---|---|
|
|
Restrict to a single repo by name |
|
all |
Lab host id to operate on (default: all docker-capable hosts) |
|
|
Force rebuild even if a context-hash tag exists |
|
|
Skip the implicit build step before compose up |
|
|
Image names to build (default: all) |
otto reservation¶
Inspect and verify lab reservations.
otto reservation whoami
otto reservation check
Reservation subcommands¶
Subcommand |
Description |
|---|---|
|
Show the resolved reservation identity and backend |
|
Verify the current reservation for the loaded lab |