pub struct ExecRequest {
pub request_id: Option<String>,
pub cmd: Vec<String>,
pub timeout_ns: u64,
pub env: Vec<String>,
pub working_dir: Option<String>,
pub rootfs: Option<String>,
pub stdin: Option<Vec<u8>>,
pub stdin_streaming: bool,
pub user: Option<String>,
pub streaming: bool,
}Expand description
Request to execute a command in the guest.
Fields§
§request_id: Option<String>Optional idempotency key for one-shot execution.
A guest that supports replay must execute the same keyed request at most once while the result remains in its bounded replay cache. The key is deliberately optional for wire compatibility with older clients. Streaming execution cannot provide an exact one-shot result replay and therefore must not set this field.
cmd: Vec<String>Command and arguments (e.g., [“ls”, “-la”]).
timeout_ns: u64Timeout in nanoseconds. 0 means use the default.
env: Vec<String>Additional environment variables (KEY=VALUE pairs).
working_dir: Option<String>Working directory for the command.
rootfs: Option<String>Optional guest-visible rootfs path to chroot into before executing.
stdin: Option<Vec<u8>>Optional stdin data to pipe to the command.
stdin_streaming: boolKeep stdin open for subsequent streaming data frames.
user: Option<String>User to run the command as (supported: “root”, “1000”, “1000:1000”).
streaming: boolEnable streaming mode (receive output chunks as they arrive).
Trait Implementations§
Source§impl Clone for ExecRequest
impl Clone for ExecRequest
Source§fn clone(&self) -> ExecRequest
fn clone(&self) -> ExecRequest
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for ExecRequest
impl Debug for ExecRequest
Source§impl<'de> Deserialize<'de> for ExecRequest
impl<'de> Deserialize<'de> for ExecRequest
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 ExecRequest
Source§impl PartialEq for ExecRequest
impl PartialEq for ExecRequest
Source§impl Serialize for ExecRequest
impl Serialize for ExecRequest
impl StructuralPartialEq for ExecRequest
Auto Trait Implementations§
impl Freeze for ExecRequest
impl RefUnwindSafe for ExecRequest
impl Send for ExecRequest
impl Sync for ExecRequest
impl Unpin for ExecRequest
impl UnsafeUnpin for ExecRequest
impl UnwindSafe for ExecRequest
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,
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.