Class: Google::Apis::VmwareengineV1::ExternalAccessRule

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/vmwareengine_v1/classes.rb,
lib/google/apis/vmwareengine_v1/representations.rb,
lib/google/apis/vmwareengine_v1/representations.rb

Overview

External access firewall rules for filtering incoming traffic destined to ExternalAddress resources.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ ExternalAccessRule

Returns a new instance of ExternalAccessRule.



526
527
528
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 526

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#actionString

The action that the external access rule performs. Corresponds to the JSON property action

Returns:

  • (String)


438
439
440
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 438

def action
  @action
end

#create_timeString

Output only. Creation time of this resource. Corresponds to the JSON property createTime

Returns:

  • (String)


443
444
445
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 443

def create_time
  @create_time
end

#descriptionString

User-provided description for this external access rule. Corresponds to the JSON property description

Returns:

  • (String)


448
449
450
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 448

def description
  @description
end

#destination_ip_rangesArray<Google::Apis::VmwareengineV1::IpRange>

If destination ranges are specified, the external access rule applies only to the traffic that has a destination IP address in these ranges. The specified IP addresses must have reserved external IP addresses in the scope of the parent network policy. To match all external IP addresses in the scope of the parent network policy, specify 0.0.0.0/0. To match a specific external IP address, specify it using the IpRange.external_address property. Corresponds to the JSON property destinationIpRanges



458
459
460
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 458

def destination_ip_ranges
  @destination_ip_ranges
end

#destination_portsArray<String>

A list of destination ports to which the external access rule applies. This field is only applicable for the UDP or TCP protocol. Each entry must be either an integer or a range. For example: ["22"], ["80","443"], or [" 12345-12349"]. To match all destination ports, specify ["0-65535"]. Corresponds to the JSON property destinationPorts

Returns:

  • (Array<String>)


466
467
468
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 466

def destination_ports
  @destination_ports
end

#ip_protocolString

The IP protocol to which the external access rule applies. This value can be one of the following three protocol strings (not case-sensitive): tcp, udp, or icmp. Corresponds to the JSON property ipProtocol

Returns:

  • (String)


473
474
475
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 473

def ip_protocol
  @ip_protocol
end

#nameString

Output only. The resource name of this external access rule. Resource names are schemeless URIs that follow the conventions in https://cloud.google.com/ apis/design/resource_names. For example: projects/my-project/locations/us- central1/networkPolicies/my-policy/externalAccessRules/my-rule Corresponds to the JSON property name

Returns:

  • (String)


481
482
483
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 481

def name
  @name
end

#priorityFixnum

External access rule priority, which determines the external access rule to use when multiple rules apply. If multiple rules have the same priority, their ordering is non-deterministic. If specific ordering is required, assign unique priorities to enforce such ordering. The external access rule priority is an integer from 100 to 4096, both inclusive. Lower integers indicate higher precedence. For example, a rule with priority 100 has higher precedence than a rule with priority 101. Corresponds to the JSON property priority

Returns:

  • (Fixnum)


492
493
494
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 492

def priority
  @priority
end

#source_ip_rangesArray<Google::Apis::VmwareengineV1::IpRange>

If source ranges are specified, the external access rule applies only to traffic that has a source IP address in these ranges. These ranges can either be expressed in the CIDR format or as an IP address. As only inbound rules are supported, ExternalAddress resources cannot be the source IP addresses of an external access rule. To match all source addresses, specify 0.0.0.0/0. Corresponds to the JSON property sourceIpRanges



501
502
503
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 501

def source_ip_ranges
  @source_ip_ranges
end

#source_portsArray<String>

A list of source ports to which the external access rule applies. This field is only applicable for the UDP or TCP protocol. Each entry must be either an integer or a range. For example: ["22"], ["80","443"], or ["12345-12349"] . To match all source ports, specify ["0-65535"]. Corresponds to the JSON property sourcePorts

Returns:

  • (Array<String>)


509
510
511
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 509

def source_ports
  @source_ports
end

#stateString

Output only. The state of the resource. Corresponds to the JSON property state

Returns:

  • (String)


514
515
516
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 514

def state
  @state
end

#uidString

Output only. System-generated unique identifier for the resource. Corresponds to the JSON property uid

Returns:

  • (String)


519
520
521
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 519

def uid
  @uid
end

#update_timeString

Output only. Last update time of this resource. Corresponds to the JSON property updateTime

Returns:

  • (String)


524
525
526
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 524

def update_time
  @update_time
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 531

def update!(**args)
  @action = args[:action] if args.key?(:action)
  @create_time = args[:create_time] if args.key?(:create_time)
  @description = args[:description] if args.key?(:description)
  @destination_ip_ranges = args[:destination_ip_ranges] if args.key?(:destination_ip_ranges)
  @destination_ports = args[:destination_ports] if args.key?(:destination_ports)
  @ip_protocol = args[:ip_protocol] if args.key?(:ip_protocol)
  @name = args[:name] if args.key?(:name)
  @priority = args[:priority] if args.key?(:priority)
  @source_ip_ranges = args[:source_ip_ranges] if args.key?(:source_ip_ranges)
  @source_ports = args[:source_ports] if args.key?(:source_ports)
  @state = args[:state] if args.key?(:state)
  @uid = args[:uid] if args.key?(:uid)
  @update_time = args[:update_time] if args.key?(:update_time)
end