pub struct AgentInstallSection {
pub nats_url: Option<String>,
pub nats_token: Option<String>,
pub nats_token_set: bool,
pub nats_user: Option<String>,
pub nats_user_set: bool,
pub nats_password: Option<String>,
pub nats_password_set: bool,
pub require_signed_commands: Option<bool>,
}Expand description
Self-service agent-installer knobs (GET /api/agents/installer) —
what the generated ZIP bakes in for a fresh PC. Kept server-side so the
restricted “download user” (viewer + the agent-install feature only)
never chooses — and never sees — these values.
Fields§
§nats_url: Option<String>NATS URL baked into the installer’s agent.toml. None → the backend’s
own configured [nats] url.
nats_token: Option<String>NATS token baked into install-agent.ps1. WRITE-ONLY: redacted from every GET response (GET /api/server-settings is viewer+).
nats_token_set: boolRead-only indicator computed by redacted() so the SPA can show “configured” without ever seeing the value. Never accepted from PUT.
nats_user: Option<String>Agent-role NATS user baked into the installer next to the token, so a
host installed today already holds the credential the broker will
later require. Shared by every agent by design. WRITE-ONLY exactly
like nats_token, and a pair with nats_password: the installer
embeds them only when both are present.
nats_user_set: boolRead-only indicator for nats_user, computed by redacted().
nats_password: Option<String>Password for nats_user. WRITE-ONLY, see nats_user.
nats_password_set: boolRead-only indicator for nats_password, computed by redacted().
require_signed_commands: Option<bool>Ask the generated Windows installer to pass -RequireSignedCommands
to deploy-agent.ps1, so a fresh agent starts enforcing signed
commands from first boot instead of leaving that as a manual
post-install step (#1155/#1165 day-1 gap).
None/Some(false) → omitted, matching every other unset knob here.
Some(true) is honored by the installer ONLY when this backend also
has a command-signing key configured — see
agent_installer::resolve_enforcement. A backend with no key must
never generate an installer that turns on enforcement with an empty
keyring; that request is instead surfaced in the installer’s
README.txt rather than silently dropped.
Trait Implementations§
Source§impl Clone for AgentInstallSection
impl Clone for AgentInstallSection
Source§impl Debug for AgentInstallSection
impl Debug for AgentInstallSection
Source§impl Default for AgentInstallSection
impl Default for AgentInstallSection
Source§impl<'de> Deserialize<'de> for AgentInstallSectionwhere
AgentInstallSection: Default,
impl<'de> Deserialize<'de> for AgentInstallSectionwhere
AgentInstallSection: Default,
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>,
impl Eq for AgentInstallSection
Source§impl PartialEq for AgentInstallSection
impl PartialEq for AgentInstallSection
Source§impl Serialize for AgentInstallSection
impl Serialize for AgentInstallSection
impl StructuralPartialEq for AgentInstallSection
Auto Trait Implementations§
impl Freeze for AgentInstallSection
impl RefUnwindSafe for AgentInstallSection
impl Send for AgentInstallSection
impl Sync for AgentInstallSection
impl Unpin for AgentInstallSection
impl UnsafeUnpin for AgentInstallSection
impl UnwindSafe for AgentInstallSection
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.