pub struct LinuxSandboxSecurityContext {
pub namespace_options: Option<NamespaceOption>,
pub selinux_options: Option<SeLinuxOption>,
pub run_as_user: Option<Int64Value>,
pub run_as_group: Option<Int64Value>,
pub readonly_rootfs: bool,
pub supplemental_groups: Vec<i64>,
pub privileged: bool,
pub seccomp: Option<SecurityProfile>,
pub apparmor: Option<SecurityProfile>,
pub seccomp_profile_path: String,
}Expand description
LinuxSandboxSecurityContext holds linux security configuration that will be applied to a sandbox. Note that:
- It does not apply to containers in the pods.
- It may not be applicable to a PodSandbox which does not contain any running process.
Fields§
§namespace_options: Option<NamespaceOption>Configurations for the sandbox’s namespaces. This will be used only if the PodSandbox uses namespace for isolation.
selinux_options: Option<SeLinuxOption>Optional SELinux context to be applied.
run_as_user: Option<Int64Value>UID to run sandbox processes as, when applicable.
run_as_group: Option<Int64Value>GID to run sandbox processes as, when applicable. run_as_group should only be specified when run_as_user is specified; otherwise, the runtime MUST error.
readonly_rootfs: boolIf set, the root filesystem of the sandbox is read-only.
supplemental_groups: Vec<i64>List of groups applied to the first process run in the sandbox, in addition to the sandbox’s primary GID.
privileged: boolIndicates whether the sandbox will be asked to run a privileged container. If a privileged container is to be executed within it, this MUST be true. This allows a sandbox to take additional security precautions if no privileged containers are expected to be run.
seccomp: Option<SecurityProfile>Seccomp profile for the sandbox.
apparmor: Option<SecurityProfile>AppArmor profile for the sandbox.
seccomp_profile_path: StringSeccomp profile for the sandbox, candidate values are:
- runtime/default: the default profile for the container runtime
- unconfined: unconfined profile, ie, no seccomp sandboxing
- localhost/
: the profile installed on the node. is the full path of the profile. Default: “”, which is identical with unconfined.
Trait Implementations§
Source§impl Clone for LinuxSandboxSecurityContext
impl Clone for LinuxSandboxSecurityContext
Source§fn clone(&self) -> LinuxSandboxSecurityContext
fn clone(&self) -> LinuxSandboxSecurityContext
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for LinuxSandboxSecurityContext
impl Debug for LinuxSandboxSecurityContext
Source§impl<'de> Deserialize<'de> for LinuxSandboxSecurityContext
impl<'de> Deserialize<'de> for LinuxSandboxSecurityContext
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>,
Source§impl Message for LinuxSandboxSecurityContext
impl Message for LinuxSandboxSecurityContext
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Source§fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>
fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>
Source§fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>
fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>
Source§fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn decode<B>(buf: B) -> Result<Self, DecodeError>
fn decode<B>(buf: B) -> Result<Self, DecodeError>
Source§fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>
fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>
Source§fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>
fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>
self. Read moreSource§fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>
fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>
self.impl StructuralPartialEq for LinuxSandboxSecurityContext
Auto Trait Implementations§
impl Freeze for LinuxSandboxSecurityContext
impl RefUnwindSafe for LinuxSandboxSecurityContext
impl Send for LinuxSandboxSecurityContext
impl Sync for LinuxSandboxSecurityContext
impl Unpin for LinuxSandboxSecurityContext
impl UnwindSafe for LinuxSandboxSecurityContext
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,
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> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request