Skip to main content

systemprompt_cli/commands/admin/identity/
mod.rs

1//! `admin identity` command tree: the secrets every replica must share.
2//!
3//! Copyright (c) systemprompt.io — Business Source License 1.1.
4//! See <https://systemprompt.io> for licensing details.
5
6mod generate;
7
8use anyhow::Result;
9use clap::Subcommand;
10
11use crate::context::CommandContext;
12
13#[derive(Clone, Copy, Debug, Subcommand)]
14pub enum IdentityCommands {
15    #[command(
16        about = "Mint oauth_at_rest_pepper, manifest_signing_secret_seed and signing_key_pem in \
17                 the encodings the secrets loader expects; never writes a file"
18    )]
19    Generate(generate::GenerateArgs),
20}
21
22pub fn execute(cmd: IdentityCommands, ctx: &CommandContext) -> Result<()> {
23    match cmd {
24        IdentityCommands::Generate(args) => generate::execute(args, ctx),
25    }
26}