Configuration Reference

This page consolidates the configuration details that are currently spread across the README and CLI source definitions.

Global connection options

The following options are shared by most execution commands through global CLI flags.

OptionSourceDescription
--hostCLIDevice hostname or IP address
--credentialCLIReusable device credential name or stable ID
--ssh-port, -PCLISSH port
--ssh-securityCLISSH compatibility profile: secure, balanced, legacy-compatible
--linux-shell-flavorCLILinux shell exit-code parsing mode: posix (bash alias) or fish
--device-profile, -dCLIDevice profile name, default autodetect
--connectionCLIUse a saved connection by name
--save-connectionCLISave the effective resolved connection after success
--template-dirCLI / RAUTO_TEMPLATE_DIRDeprecated legacy option; templates and custom profiles are now stored in SQLite
--force-autodetectCLIIgnore the cached autodetect result and probe the target again
--session-retriesCLI / RAUTO_SESSION_RETRIESOpt-in retries for transient ordinary-session failures; default 0
--retry-initial-backoff-msCLI / RAUTO_RETRY_INITIAL_BACKOFF_MSInitial retry delay; default 200 ms
--retry-max-backoff-msCLI / RAUTO_RETRY_MAX_BACKOFF_MSCapped exponential backoff; default 2000 ms
--retry-authentication-errorsCLI / RAUTO_RETRY_AUTHENTICATION_ERRORSAlso retry authentication rejections; disabled by default

Runtime environment variables

rauto currently exposes a small set of environment-based defaults.

Env varUsed byDescription
RAUTO_MANAGER_URLrauto agentDefault manager base URL
RAUTO_AGENT_NAMErauto agentDefault agent name
RAUTO_AGENT_TOKENrauto agentDefault agent authentication token
RAUTO_MANAGER_REPORT_MODErauto agentDefault reporting transport
RAUTO_AGENT_PROBE_REPORT_INTERVALrauto agentDefault liveness probe reporting interval
RAUTO_HOMEruntime layoutOverride the default runtime root (~/.rauto)
RAUTO_SESSION_RETRIESordinary sessionsDefault transient retry count
RAUTO_RETRY_INITIAL_BACKOFF_MSordinary sessionsInitial retry delay
RAUTO_RETRY_MAX_BACKOFF_MSordinary sessionsMaximum retry backoff
RAUTO_RETRY_AUTHENTICATION_ERRORSordinary sessionsInclude authentication failures in retries

Default runtime layout

By default, runtime data is stored under:

~/.rauto
├── rauto.db
└── backups/

What lives there:

  • rauto.db
    • saved connections
    • optional saved-connection device model and software version facts
    • unified session records and replay events
    • latest device discovery run and results
    • config fetch command overrides and volatile-line patterns
    • blacklist rules
    • custom device profiles
    • command templates
    • command flow templates
    • custom TextFSM templates and command mappings
    • custom show objects
    • execution template metadata
  • backups/
    • generated .tar.gz archives

Execution recording options

Several execution commands share the same recording model.

OptionCommandsDescription
--record-file <path>exec, template, flow, upload, tx, tx-workflowExport a JSONL recording file
--record-level key-events-onlysameMinimal audit recording
--record-level fullsameRicher prompt/state recording

The RecordLevelOpt source definition currently exposes two values:

  • KeyEventsOnly
  • Full

Command-specific configuration

rauto exec

OptionDescription
--mode, -mOne mode or ordered comma/pipe-separated candidates such as Enable,Config or `Root
--target / --group / --labelRepeatable selectors forming a deduplicated multi-target union
--max-parallelMaximum active multi-target sessions; default 4
--parse-textfsmParse output with TextFSM, inferring platform from the resolved profile when possible
--textfsm-template <path>Use a specific TextFSM template file
--textfsm-platform <platform>Override inferred NTC TextFSM platform
--textfsm-excel <file.xlsx>Export successful parsed rows to an Excel workbook; also enables parsing
--textfsm-strict-errorsKeep TextFSM -> Error rules instead of filtering them before parsing

flow, show, and config fetch share the same repeatable target selectors and bounded concurrency model.

rauto show

OptionDescription
objectShow object such as version, interfaces, route, arp, lldp, mac, or vlan
--listList available show objects for the selected or resolved platform
--target <connection>Repeatable saved connection target for CLI batch show; CLI batch show runs one object across selected targets
--group <group>Repeatable inventory group selector for batch show
--label <label> / --tag <label>Repeatable saved connection label selector for batch show
--textfsm-platform <platform>Override platform for command selection and parsing
--mode, -mOverride the mode from the show catalog or profile default; matching is case-insensitive
--print-commandPrint the resolved device command before execution
--no-parseDisable the default TextFSM parsing for show output; cannot be combined with --textfsm-excel
--textfsm-excel <file.xlsx>Export successful parsed rows to Excel; also enables parsing
--textfsm-strict-errorsKeep TextFSM -> Error rules instead of filtering them before parsing

rauto template

OptionDescription
--vars, -vJSON or YAML file used as the render context
--parse-textfsmParse command output with TextFSM
--textfsm-template <path>Repeatable template files matched by command order
--textfsm-platform <platform>Override inferred NTC TextFSM platform
--textfsm-excel <file.xlsx>Export successful parsed rows to Excel; also enables parsing
--textfsm-strict-errorsKeep TextFSM -> Error rules instead of filtering them before parsing
--dry-runRender without executing

rauto flow

OptionDescription
--templateSaved command flow template name
--fileAd-hoc TOML command flow template
--vars, -vJSON file containing runtime variables
--vars-jsonInline JSON runtime variables
--parse-textfsmParse command output with TextFSM
--textfsm-template <path>Repeatable template files matched by command order
--textfsm-platform <platform>Override inferred NTC TextFSM platform
--textfsm-excel <file.xlsx>Export successful parsed rows to Excel; also enables parsing
--textfsm-strict-errorsKeep TextFSM -> Error rules instead of filtering them before parsing

rauto upload

OptionDescription
--local-pathLocal file path on the machine running rauto
--remote-pathDestination path on the remote target
--timeout-secsUpload timeout, default 300
--buffer-sizeOptional transfer buffer size
--show-progressEmit progress logs during transfer

rauto tx

The source code exposes a richer set of tx controls than the current docs homepage covers.

OptionDescription
--nameTransaction block name used in logs and recordings
--run-kindcommands or command-flow
--templateRender commands from a stored template
--varsVariables file for --template
--flow-template / --flow-fileMain command-flow source
--flow-vars / --flow-vars-jsonMain command-flow runtime variables
--rollback-flow-template / --rollback-flow-fileRollback flow source
--rollback-flow-vars / --rollback-flow-vars-jsonRollback flow variables
--commandRepeatable command input in command mode
--rollback-commandRepeatable per-step rollback commands
--rollback-commands-fileOne rollback command per line
--rollback-commands-jsonJSON array of rollback commands
--rollback-on-failureRoll back the failed step itself when using per-step rollback
--rollback-trigger-step-indexStep index that triggers whole-resource rollback
--modeTarget mode for generated steps or command flow execution
--timeout-secsPer-step timeout
--resource-rollback-commandExplicit whole-resource rollback command
--dry-runPrint normalized tx plan without executing
--jsonOutput tx result as JSON

rauto tx-workflow

OptionDescription
workflow_fileRequired JSON workflow path
--dry-runPrint normalized plan and exit
--viewRender a terminal visualization of the workflow
--jsonOutput raw workflow result JSON

rauto orchestrate

OptionDescription
plan_fileRequired orchestration plan JSON path
--dry-runPrint normalized plan and exit
--viewRender a terminal visualization of the orchestration
--jsonOutput orchestration result as JSON
--record-levelRecording level applied to target executions

rauto config fetch

OptionDescription
--kindConfiguration catalog kind, default running
--target / --group / --labelRepeatable saved-target selectors
--max-parallelBounded concurrent device sessions, default 4
--outputExact output file for one target
--output-dirTimestamped files for multiple targets
--normalizedPrint or store volatile-line-filtered content

rauto session replay

OptionDescription
record_fileOptional JSONL recording; otherwise use a database record
--idDatabase session record ID; defaults to the newest record
--listList recorded command output events
--commandReplay a specific command
--modeOptional mode filter when replaying

Agent configuration

rauto agent combines CLI flags, environment variables, and optional config file defaults.

Agent CLI flags

OptionDefaultDescription
--bind0.0.0.0Agent bind address
--port8123Agent listen port
--manager-urlnoneManager URL for registration and reporting
--agent-namenoneGlobally unique agent name
--agent-tokennoneShared secret for manager callbacks and auth
--report-modenoneManager report transport
--agent-config~/.rauto/agent.tomlOptional config file path
--probe-report-intervalnonePeriodic device liveness reporting interval in seconds

Agent config file example

[manager]
url = "http://manager:50051"
token = "my-secret-token"
report_mode = "grpc"

[agent]
name = "agent-beijing-01"
heartbeat_interval = 30
probe_report_interval = 300

TextFSM customization model

Custom TextFSM data is stored in SQLite.

  • custom_textfsm_templates stores named TextFSM template content.
  • custom_textfsm_mappings binds (device_profile, command) to a template name.
  • Exact commands are normalized before lookup.
  • Custom mappings are checked before bundled NTC templates.
  • TextFSM parsing is lenient by default: fallback Error rules are filtered before parsing.
  • Pass --textfsm-strict-errors on show, exec, template, or flow to preserve those Error rules.
  • For exec, template, and flow, parsing is enabled by --parse-textfsm, --textfsm-template, or --textfsm-excel.

Custom show object model

Custom show objects are stored in SQLite and keyed by (device_profile, object).

  • They override bundled show mappings for the same profile and object.
  • Object names are normalized, so aliases and punctuation resolve consistently.
  • A custom object can set a command, optional execution mode, and optional TextFSM template.
  • A custom object can also reference an existing profile-command TextFSM mapping by textfsm_mapping_command.
  • When textfsm_mapping_command is set, that mapped command becomes the effective show command and any direct custom-object TextFSM template binding is cleared.
  • Disabled custom objects remain stored but are ignored during resolution.

Web API template stores

The Svelte Web UI and local API expose reusable JSON template stores in addition to CLI command-template stores.

API familyPurpose
/api/tx-block-templatesStore reusable transaction block JSON templates
/api/tx-workflow-templatesStore reusable transaction workflow JSON templates
/api/orchestration-templatesStore reusable orchestration JSON templates

CLI management commands currently exist for tx-workflow template ... and orchestrate template ...; tx block JSON templates are managed through Web/API and executed through the tx block API flow.

The Web connection editor uses /api/connection/detect-facts to run the resolved Profile's version query and return parsed device facts. A partial parse is returned with a warning instead of discarding facts already entered by the operator.

Inventory configuration model

Current inventory behavior is source-of-truth driven by saved connections.

  • There is no separate persistent target database for inventory records.
  • Saved connections hold target identity, labels, groups, and vars.
  • Inventory CLI focuses on group management.
  • Groups contain only a name, optional description, and saved connection host names.

Operational defaults and guardrails

From the source and current README behavior:

  • default device profile is autodetect
  • Web console default bind is 127.0.0.1:3000
  • first-run Web startup generates a password in ~/.rauto/config.toml; unauthenticated APIs return 401
  • agent default bind is 0.0.0.0:8123
  • upload timeout defaults to 300 seconds
  • tx default name is tx-block
  • successful autodetect results are cached by host:port
  • session replay reads database records or JSONL recordings produced by execution commands
  • credential secrets are encrypted in SQLite, while the master key remains in the operating system keyring