Skip to content

control

Structs

Functions

  • run - Runs the Policy Control event loop.

Struct

Options used to start Policy Control.

Methods:

  • fn with_audit_rows(audit_rows: Receiver<AuditRow>) -> Self - Creates options backed by a live audit row receiver.
  • fn with_policy_dir(self: Self, policy_dir: PathBuf) -> Self - Records the Authority policy directory resolved by the CLI service.

Trait Implementations:

  • Default
    • fn default() -> ControlOptions

Function

Runs the Policy Control event loop.

Terminal setup, input polling, and drawing errors are returned to the caller. Terminal cleanup is still attempted when setup partially succeeds.

Returns an error when terminal setup, event polling, or drawing fails.

fn run(options: &ControlOptions) -> anyhow::Result<std::process::ExitCode>