pub struct ContainerToContainerRule {
pub network: String,
pub src_container: Option<String>,
pub dst_container: Option<String>,
pub matches: Option<String>,
pub verdict: RuleVerdict,
}Expand description
Definition for a rule to be used in the container-to-container section.
Fields§
§network: StringCommon network between the source container and the destination container to apply the rule to.
src_container: Option<String>Source container to apply the rule to.
dst_container: Option<String>Destination container to apply the rule to.
matches: Option<String>Additional match-string, which will be added to the nftables command.
verdict: RuleVerdictVerdict for rule (accept, drop or reject).
Trait Implementations§
Source§impl Clone for ContainerToContainerRule
impl Clone for ContainerToContainerRule
Source§fn clone(&self) -> ContainerToContainerRule
fn clone(&self) -> ContainerToContainerRule
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ContainerToContainerRule
impl Debug for ContainerToContainerRule
Source§impl<'de> Deserialize<'de> for ContainerToContainerRule
impl<'de> Deserialize<'de> for ContainerToContainerRule
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>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for ContainerToContainerRule
Source§impl Hash for ContainerToContainerRule
impl Hash for ContainerToContainerRule
Source§impl PartialEq for ContainerToContainerRule
impl PartialEq for ContainerToContainerRule
Source§impl Process<Iptables> for ContainerToContainerRule
impl Process<Iptables> for ContainerToContainerRule
Source§fn process(
&self,
ctx: &ProcessContext<'_, Iptables>,
) -> Result<Option<Vec<IptablesRule>>>
fn process( &self, ctx: &ProcessContext<'_, Iptables>, ) -> Result<Option<Vec<IptablesRule>>>
Process the current type within the given
ProcessContext, returning zero or more rules
to apply with nft.Source§impl Process<Nftables> for ContainerToContainerRule
impl Process<Nftables> for ContainerToContainerRule
Source§fn process(
&self,
ctx: &ProcessContext<'_, Nftables>,
) -> Result<Option<Vec<String>>>
fn process( &self, ctx: &ProcessContext<'_, Nftables>, ) -> Result<Option<Vec<String>>>
Process the current type within the given
ProcessContext, returning zero or more rules
to apply with nft.impl StructuralPartialEq for ContainerToContainerRule
Auto Trait Implementations§
impl Freeze for ContainerToContainerRule
impl RefUnwindSafe for ContainerToContainerRule
impl Send for ContainerToContainerRule
impl Sync for ContainerToContainerRule
impl Unpin for ContainerToContainerRule
impl UnsafeUnpin for ContainerToContainerRule
impl UnwindSafe for ContainerToContainerRule
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,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.