pub struct Linux { /* private fields */ }
Expand description
Linux contains platform-specific configuration for Linux based containers.
Implementations§
source§impl Linux
impl Linux
sourcepub fn uid_mappings(&self) -> &Option<Vec<LinuxIdMapping>>
pub fn uid_mappings(&self) -> &Option<Vec<LinuxIdMapping>>
UIDMappings specifies user mappings for supporting user namespaces.
sourcepub fn gid_mappings(&self) -> &Option<Vec<LinuxIdMapping>>
pub fn gid_mappings(&self) -> &Option<Vec<LinuxIdMapping>>
GIDMappings specifies group mappings for supporting user namespaces.
sourcepub fn sysctl(&self) -> &Option<HashMap<String, String>>
pub fn sysctl(&self) -> &Option<HashMap<String, String>>
Sysctl are a set of key value pairs that are set for the container on start.
sourcepub fn resources(&self) -> &Option<LinuxResources>
pub fn resources(&self) -> &Option<LinuxResources>
Resources contain cgroup information for handling resource constraints for the container.
sourcepub fn cgroups_path(&self) -> &Option<PathBuf>
pub fn cgroups_path(&self) -> &Option<PathBuf>
CgroupsPath specifies the path to cgroups that are created and/or joined by the container. The path is expected to be relative to the cgroups mountpoint. If resources are specified, the cgroups at CgroupsPath will be updated based on resources.
sourcepub fn namespaces(&self) -> &Option<Vec<LinuxNamespace>>
pub fn namespaces(&self) -> &Option<Vec<LinuxNamespace>>
Namespaces contains the namespaces that are created and/or joined by the container.
sourcepub fn devices(&self) -> &Option<Vec<LinuxDevice>>
pub fn devices(&self) -> &Option<Vec<LinuxDevice>>
Devices are a list of device nodes that are created for the container.
sourcepub fn seccomp(&self) -> &Option<LinuxSeccomp>
pub fn seccomp(&self) -> &Option<LinuxSeccomp>
Seccomp specifies the seccomp security settings for the container.
sourcepub fn rootfs_propagation(&self) -> &Option<String>
pub fn rootfs_propagation(&self) -> &Option<String>
RootfsPropagation is the rootfs mount propagation mode for the container.
sourcepub fn masked_paths(&self) -> &Option<Vec<String>>
pub fn masked_paths(&self) -> &Option<Vec<String>>
MaskedPaths masks over the provided paths inside the container.
sourcepub fn readonly_paths(&self) -> &Option<Vec<String>>
pub fn readonly_paths(&self) -> &Option<Vec<String>>
ReadonlyPaths sets the provided paths as RO inside the container.
sourcepub fn mount_label(&self) -> &Option<String>
pub fn mount_label(&self) -> &Option<String>
MountLabel specifies the selinux context for the mounts in the container.
sourcepub fn intel_rdt(&self) -> &Option<LinuxIntelRdt>
pub fn intel_rdt(&self) -> &Option<LinuxIntelRdt>
IntelRdt contains Intel Resource Director Technology (RDT) information for handling resource constraints and monitoring metrics (e.g., L3 cache, memory bandwidth) for the container.
sourcepub fn personality(&self) -> &Option<LinuxPersonality>
pub fn personality(&self) -> &Option<LinuxPersonality>
Personality contains configuration for the Linux personality syscall.
source§impl Linux
impl Linux
sourcepub fn set_uid_mappings(
&mut self,
val: Option<Vec<LinuxIdMapping>>
) -> &mut Self
pub fn set_uid_mappings( &mut self, val: Option<Vec<LinuxIdMapping>> ) -> &mut Self
UIDMappings specifies user mappings for supporting user namespaces.
sourcepub fn set_gid_mappings(
&mut self,
val: Option<Vec<LinuxIdMapping>>
) -> &mut Self
pub fn set_gid_mappings( &mut self, val: Option<Vec<LinuxIdMapping>> ) -> &mut Self
GIDMappings specifies group mappings for supporting user namespaces.
sourcepub fn set_sysctl(&mut self, val: Option<HashMap<String, String>>) -> &mut Self
pub fn set_sysctl(&mut self, val: Option<HashMap<String, String>>) -> &mut Self
Sysctl are a set of key value pairs that are set for the container on start.
sourcepub fn set_resources(&mut self, val: Option<LinuxResources>) -> &mut Self
pub fn set_resources(&mut self, val: Option<LinuxResources>) -> &mut Self
Resources contain cgroup information for handling resource constraints for the container.
sourcepub fn set_cgroups_path(&mut self, val: Option<PathBuf>) -> &mut Self
pub fn set_cgroups_path(&mut self, val: Option<PathBuf>) -> &mut Self
CgroupsPath specifies the path to cgroups that are created and/or joined by the container. The path is expected to be relative to the cgroups mountpoint. If resources are specified, the cgroups at CgroupsPath will be updated based on resources.
sourcepub fn set_namespaces(&mut self, val: Option<Vec<LinuxNamespace>>) -> &mut Self
pub fn set_namespaces(&mut self, val: Option<Vec<LinuxNamespace>>) -> &mut Self
Namespaces contains the namespaces that are created and/or joined by the container.
sourcepub fn set_devices(&mut self, val: Option<Vec<LinuxDevice>>) -> &mut Self
pub fn set_devices(&mut self, val: Option<Vec<LinuxDevice>>) -> &mut Self
Devices are a list of device nodes that are created for the container.
sourcepub fn set_seccomp(&mut self, val: Option<LinuxSeccomp>) -> &mut Self
pub fn set_seccomp(&mut self, val: Option<LinuxSeccomp>) -> &mut Self
Seccomp specifies the seccomp security settings for the container.
sourcepub fn set_rootfs_propagation(&mut self, val: Option<String>) -> &mut Self
pub fn set_rootfs_propagation(&mut self, val: Option<String>) -> &mut Self
RootfsPropagation is the rootfs mount propagation mode for the container.
sourcepub fn set_masked_paths(&mut self, val: Option<Vec<String>>) -> &mut Self
pub fn set_masked_paths(&mut self, val: Option<Vec<String>>) -> &mut Self
MaskedPaths masks over the provided paths inside the container.
sourcepub fn set_readonly_paths(&mut self, val: Option<Vec<String>>) -> &mut Self
pub fn set_readonly_paths(&mut self, val: Option<Vec<String>>) -> &mut Self
ReadonlyPaths sets the provided paths as RO inside the container.
sourcepub fn set_mount_label(&mut self, val: Option<String>) -> &mut Self
pub fn set_mount_label(&mut self, val: Option<String>) -> &mut Self
MountLabel specifies the selinux context for the mounts in the container.
sourcepub fn set_intel_rdt(&mut self, val: Option<LinuxIntelRdt>) -> &mut Self
pub fn set_intel_rdt(&mut self, val: Option<LinuxIntelRdt>) -> &mut Self
IntelRdt contains Intel Resource Director Technology (RDT) information for handling resource constraints and monitoring metrics (e.g., L3 cache, memory bandwidth) for the container.
sourcepub fn set_personality(&mut self, val: Option<LinuxPersonality>) -> &mut Self
pub fn set_personality(&mut self, val: Option<LinuxPersonality>) -> &mut Self
Personality contains configuration for the Linux personality syscall.