Skip to main content

AddServiceParams

Struct AddServiceParams 

Source
pub struct AddServiceParams<'a> {
Show 15 fields pub service_name: &'a str, pub exposure: &'a Exposure, pub auth: AuthChoice, pub enable_smtp: bool, pub enable_backup: bool, pub env_overrides: &'a BTreeMap<String, String>, pub enabled_groups: &'a BTreeSet<String>, pub selected_choices: &'a BTreeMap<String, String>, pub registry_name: &'a str, pub repo_dir: &'a Path, pub pre_built_ctx: Option<BTreeMap<String, String>>, pub port_in_use: &'a dyn Fn(u16) -> bool, pub acme_mode: Option<&'a AcmeMode>, pub mode: PlanMode, pub port_overrides: &'a BTreeMap<String, u16>,
}
Expand description

Inputs to add_service. One typed request instead of a positional argument list, so call sites (CLI today, other frontends later) name what they’re asking for and the retry path can’t drift out of sync with the original call.

Fields§

§service_name: &'a str§exposure: &'a Exposure§auth: AuthChoice§enable_smtp: bool§enable_backup: bool§env_overrides: &'a BTreeMap<String, String>§enabled_groups: &'a BTreeSet<String>§selected_choices: &'a BTreeMap<String, String>

[[choice]] selections (choice name -> option name). Choices absent from the map fall back to their declared default at render time.

§registry_name: &'a str§repo_dir: &'a Path§pre_built_ctx: Option<BTreeMap<String, String>>

When provided, its secrets and auth credentials are reused instead of generating fresh ones. Pass the context from the interactive prompt phase so the values the user saw match what gets written.

§port_in_use: &'a dyn Fn(u16) -> bool§acme_mode: Option<&'a AcmeMode>§mode: PlanMode§port_overrides: &'a BTreeMap<String, u16>

Pin specific port assignments by name (e.g. {"http": 10005}) instead of running the allocator. Used by upgrade so a re-render preserves the install’s existing host ports — port_in_use would say they’re taken (the running service holds them) and the allocator would skip to the next free one.

Auto Trait Implementations§

§

impl<'a> !RefUnwindSafe for AddServiceParams<'a>

§

impl<'a> !Send for AddServiceParams<'a>

§

impl<'a> !Sync for AddServiceParams<'a>

§

impl<'a> !UnwindSafe for AddServiceParams<'a>

§

impl<'a> Freeze for AddServiceParams<'a>

§

impl<'a> Unpin for AddServiceParams<'a>

§

impl<'a> UnsafeUnpin for AddServiceParams<'a>

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V