class Google::Apis::ComputeV1::RouterNatRule
Attributes
The action to be enforced for traffic that matches this rule. Corresponds to the JSON property `action` @return [Google::Apis::ComputeV1::RouterNatRuleAction]
An optional description of this rule. Corresponds to the JSON property `description` @return [String]
CEL expression that specifies the match condition that egress traffic from a VM is evaluated against. If it evaluates to true, the corresponding `action` is enforced. The following examples are valid match expressions for public NAT: “inIpRange(destination.ip, '1.1.0.0/16') || inIpRange(destination.ip, '2.2.0. 0/16')” “destination.ip == '1.1.0.1' || destination.ip == '8.8.8.8'” The following example is a valid match expression for private NAT: “nexthop.hub == 'networkconnectivity.googleapis.com/v1alpha1/projects/my-project/ global/hub/hub-1'” Corresponds to the JSON property `match` @return [String]
An integer uniquely identifying a rule in the list. The rule number must be a positive value between 0 and 65000, and must be unique among rules within a NAT. Corresponds to the JSON property `ruleNumber` @return [Fixnum]
Public Class Methods
# File lib/google/apis/compute_v1/classes.rb, line 30475 def initialize(**args) update!(**args) end
Public Instance Methods
Update properties of this object
# File lib/google/apis/compute_v1/classes.rb, line 30480 def update!(**args) @action = args[:action] if args.key?(:action) @description = args[:description] if args.key?(:description) @match = args[:match] if args.key?(:match) @rule_number = args[:rule_number] if args.key?(:rule_number) end