Class V1NetworkPolicyEgressRule
NetworkPolicyEgressRule describes a particular set of traffic that is allowed
out of pods matched by a NetworkPolicySpec's podSelector. The traffic must match
both ports and to. This type is beta-level in 1.8
Inheritance
V1NetworkPolicyEgressRule
Assembly: KubernetesClient.dll
Syntax
public record V1NetworkPolicyEgressRule : IEquatable<V1NetworkPolicyEgressRule>
Constructors
View Source
V1NetworkPolicyEgressRule()
Declaration
public V1NetworkPolicyEgressRule()
View Source
V1NetworkPolicyEgressRule(V1NetworkPolicyEgressRule)
Declaration
protected V1NetworkPolicyEgressRule(V1NetworkPolicyEgressRule original)
Parameters
Properties
View Source
EqualityContract
Declaration
protected virtual Type EqualityContract { get; }
Property Value
View Source
Ports
ports is a list of destination ports for outgoing traffic. Each item in this
list is combined using a logical OR. If this field is empty or missing, this
rule matches all ports (traffic not restricted by port). If this field is
present and contains at least one item, then this rule allows traffic only if
the traffic matches at least one port in the list.
Declaration
[JsonPropertyName("ports")]
public IList<V1NetworkPolicyPort> Ports { get; set; }
Property Value
View Source
To
to is a list of destinations for outgoing traffic of pods selected for this
rule. Items in this list are combined using a logical OR operation. If this
field is empty or missing, this rule matches all destinations (traffic not
restricted by destination). If this field is present and contains at least one
item, this rule allows traffic only if the traffic matches at least one item in
the to list.
Declaration
[JsonPropertyName("to")]
public IList<V1NetworkPolicyPeer> To { get; set; }
Property Value
Methods
View Source
Equals(object?)
Declaration
public override bool Equals(object? obj)
Parameters
| Type |
Name |
Description |
| object |
obj |
|
Returns
Overrides
View Source
Equals(V1NetworkPolicyEgressRule?)
Declaration
public virtual bool Equals(V1NetworkPolicyEgressRule? other)
Parameters
Returns
View Source
GetHashCode()
Declaration
public override int GetHashCode()
Returns
Overrides
View Source
PrintMembers(StringBuilder)
Declaration
protected virtual bool PrintMembers(StringBuilder builder)
Parameters
Returns
View Source
ToString()
Declaration
public override string ToString()
Returns
Overrides
Operators
View Source
operator ==(V1NetworkPolicyEgressRule?, V1NetworkPolicyEgressRule?)
Declaration
public static bool operator ==(V1NetworkPolicyEgressRule? left, V1NetworkPolicyEgressRule? right)
Parameters
Returns
View Source
operator !=(V1NetworkPolicyEgressRule?, V1NetworkPolicyEgressRule?)
Declaration
public static bool operator !=(V1NetworkPolicyEgressRule? left, V1NetworkPolicyEgressRule? right)
Parameters
Returns
Implements