pub struct Config {Show 26 fields
pub provider: Option<String>,
pub role_arn: Option<String>,
pub ttl: Option<String>,
pub budget: Option<f64>,
pub region: Option<String>,
pub deny: Option<Vec<String>>,
pub permissions_boundary: Option<String>,
pub network: Option<NetworkPolicy>,
pub profiles: HashMap<String, Profile>,
pub gcp_service_account: Option<String>,
pub gcp_project: Option<String>,
pub gcp_extended_lifetime: bool,
pub azure_subscription: Option<String>,
pub azure_tenant: Option<String>,
pub team: Option<TeamConfig>,
pub approval: Option<ApprovalConfig>,
pub audit: Option<ForwardConfig>,
pub roles: Option<RoleMappingConfig>,
pub ratelimit: Option<RateLimitConfig>,
pub sso: Option<SsoConfig>,
pub vault: Option<VaultConfig>,
pub account: Option<AccountConfig>,
pub broker: Option<BrokerConfig>,
pub mcp_allowed_commands: Option<Vec<String>>,
pub dbaudit: Option<DbAuditConfig>,
pub ha: Option<HaConfig>,
}Fields§
§provider: Option<String>Default cloud provider (“aws”, “gcp”, or “azure”)
role_arn: Option<String>Default IAM role ARN to assume (AWS)
ttl: Option<String>Default TTL for sessions (e.g. “15m”)
budget: Option<f64>Default budget limit in USD
region: Option<String>Default AWS region
deny: Option<Vec<String>>Actions that are always denied regardless of –allow
permissions_boundary: Option<String>AWS permissions boundary policy ARN — applied to every AssumeRole call as an additional ceiling beyond the inline session policy.
network: Option<NetworkPolicy>Network policy: restrict credentials to specific source IPs or VPCs.
profiles: HashMap<String, Profile>Named policy profiles
gcp_service_account: Option<String>GCP service account email for impersonation
gcp_project: Option<String>GCP project ID
gcp_extended_lifetime: boolAllow GCP access token TTLs beyond the default 1h (up to 12h).
Requires the org policy
constraints/iam.allowServiceAccountCredentialLifetimeExtension to be
enabled for the target project. If that policy is not set, the IAM
generateAccessToken API will reject requests for tokens with a
lifetime exceeding 3600s with a PERMISSION_DENIED error. Verify the
org policy is in place before enabling this flag — there is no
pre-flight API check available for org policy constraints.
To inspect the policy:
gcloud org-policies describe \
constraints/iam.allowServiceAccountCredentialLifetimeExtension \
--project=<PROJECT_ID>azure_subscription: Option<String>Azure subscription ID
azure_tenant: Option<String>Azure tenant ID
team: Option<TeamConfig>Team policy configuration
approval: Option<ApprovalConfig>Approval workflow configuration
audit: Option<ForwardConfig>Audit forwarding configuration
roles: Option<RoleMappingConfig>Role mapping configuration
ratelimit: Option<RateLimitConfig>Rate limiting configuration
sso: Option<SsoConfig>SSO configuration
vault: Option<VaultConfig>Vault credential backend configuration
account: Option<AccountConfig>Multi-account configuration
broker: Option<BrokerConfig>Credential broker configuration
mcp_allowed_commands: Option<Vec<String>>MCP command allowlist — when set, only commands whose basename matches
an entry in this list can be executed via the MCP audex_run tool.
Example: mcp_allowed_commands = ["aws", "terraform", "gcloud", "az"]
dbaudit: Option<DbAuditConfig>Database audit backend configuration (planned — parsed but not yet wired to a DB driver)
ha: Option<HaConfig>High availability configuration (planned — parsed but not yet wired to Redis/etcd)
Implementations§
Source§impl Config
impl Config
Sourcepub fn load() -> Result<Self>
pub fn load() -> Result<Self>
Load config from ~/.config/audex/config.toml. Returns default if file doesn’t exist.
Sourcepub fn resolve_profile(&self, name: &str) -> Result<Profile>
pub fn resolve_profile(&self, name: &str) -> Result<Profile>
Get a profile by name. Checks community:// prefix, then user config, then built-in profiles.
Sourcepub fn all_profiles(&self) -> Vec<(String, Profile)>
pub fn all_profiles(&self) -> Vec<(String, Profile)>
List all available profiles (user + built-in).
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Config
impl<'de> Deserialize<'de> for Config
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Auto Trait Implementations§
impl Freeze for Config
impl RefUnwindSafe for Config
impl Send for Config
impl Sync for Config
impl Unpin for Config
impl UnsafeUnpin for Config
impl UnwindSafe for Config
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<D> DeserializeWith<JsonFormat> for Dwhere
D: DeserializeOwned,
impl<D> DeserializeWith<JsonFormat> for Dwhere
D: DeserializeOwned,
Source§fn deserialize_with(body: ResponseBody) -> Result<D, Error>
fn deserialize_with(body: ResponseBody) -> Result<D, Error>
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more