pub struct Detached {
pub microvm_id: String,
pub endpoint: String,
pub region: Region,
pub port: u16,
/* private fields */
}Expand description
What another process needs to adopt a VM this sandbox handed off with
Sandbox::detach: pass the fields to Sandbox::adopt (or the prelude’s Sandbox::adopt_in).
The agent token is a credential: readable through Detached::agent_token so it can be
persisted, and absent from Debug, so a log line that formats the record cannot leak it.
Store it the way crate::names::NameRecord asks: privately, encrypted.
Fields§
§microvm_id: StringThe VM’s identifier.
endpoint: StringThe HTTPS endpoint its daemon answers on.
region: RegionThe region the VM runs in.
port: u16The daemon port the endpoint’s proxy tokens are minted for.
Implementations§
Source§impl Detached
impl Detached
Sourcepub fn agent_token(&self) -> &str
pub fn agent_token(&self) -> &str
The bearer the VM’s daemon accepts; required by Sandbox::adopt.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Detached
impl RefUnwindSafe for Detached
impl Send for Detached
impl Sync for Detached
impl Unpin for Detached
impl UnsafeUnpin for Detached
impl UnwindSafe for Detached
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
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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> ⓘ
Converts
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> ⓘ
Converts
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 moreCreates a shared type from an unshared type.