pub struct Exec {Show 18 fields
pub console_socket: Option<PathBuf>,
pub cwd: Option<PathBuf>,
pub env: Vec<(String, String)>,
pub tty: bool,
pub user: Option<(u32, Option<u32>)>,
pub additional_gids: Vec<u32>,
pub process: Option<PathBuf>,
pub detach: bool,
pub pid_file: Option<PathBuf>,
pub process_label: Option<String>,
pub apparmor: Option<String>,
pub no_new_privs: bool,
pub cap: Vec<String>,
pub preserve_fds: i32,
pub ignore_paused: bool,
pub cgroup: Option<String>,
pub container_id: String,
pub command: Vec<String>,
}
Expand description
Execute a process within an existing container Reference: https://github.com/opencontainers/runc/blob/main/man/runc-exec.8.md
Fields§
§console_socket: Option<PathBuf>
Unix socket (file) path , which will receive file descriptor of the writing end of the pseudoterminal
cwd: Option<PathBuf>
Current working directory of the container
env: Vec<(String, String)>
Environment variables that should be set in the container
tty: bool
§user: Option<(u32, Option<u32>)>
Run the command as a user
additional_gids: Vec<u32>
Add additional group IDs. Can be specified multiple times
process: Option<PathBuf>
Path to process.json
detach: bool
Detach from the container process
pid_file: Option<PathBuf>
The file to which the pid of the container process should be written to
process_label: Option<String>
Set the asm process label for the process commonly used with selinux
apparmor: Option<String>
Set the apparmor profile for the process
no_new_privs: bool
Prevent the process from gaining additional privileges
cap: Vec<String>
Add a capability to the bounding set for the process
preserve_fds: i32
Pass N additional file descriptors to the container
ignore_paused: bool
Allow exec in a paused container
cgroup: Option<String>
Execute a process in a sub-cgroup
container_id: String
Identifier of the container
command: Vec<String>
Command that should be executed in the container
Trait Implementations§
Source§impl Args for Exec
impl Args for Exec
Source§fn augment_args<'b>(__clap_app: Command) -> Command
fn augment_args<'b>(__clap_app: Command) -> Command
Source§fn augment_args_for_update<'b>(__clap_app: Command) -> Command
fn augment_args_for_update<'b>(__clap_app: Command) -> Command
Command
so it can instantiate self
via
FromArgMatches::update_from_arg_matches_mut
Read moreSource§impl CommandFactory for Exec
impl CommandFactory for Exec
Source§impl FromArgMatches for Exec
impl FromArgMatches for Exec
Source§fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>
fn from_arg_matches(__clap_arg_matches: &ArgMatches) -> Result<Self, Error>
Source§fn from_arg_matches_mut(
__clap_arg_matches: &mut ArgMatches,
) -> Result<Self, Error>
fn from_arg_matches_mut( __clap_arg_matches: &mut ArgMatches, ) -> Result<Self, Error>
Source§fn update_from_arg_matches(
&mut self,
__clap_arg_matches: &ArgMatches,
) -> Result<(), Error>
fn update_from_arg_matches( &mut self, __clap_arg_matches: &ArgMatches, ) -> Result<(), Error>
ArgMatches
to self
.Source§fn update_from_arg_matches_mut(
&mut self,
__clap_arg_matches: &mut ArgMatches,
) -> Result<(), Error>
fn update_from_arg_matches_mut( &mut self, __clap_arg_matches: &mut ArgMatches, ) -> Result<(), Error>
ArgMatches
to self
.