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.



1026
1027
1028
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 1026

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)


938
939
940
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 938

def action
  @action
end

#create_timeString

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

Returns:

  • (String)


943
944
945
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 943

def create_time
  @create_time
end

#descriptionString

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

Returns:

  • (String)


948
949
950
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 948

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



958
959
960
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 958

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>)


966
967
968
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 966

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)


973
974
975
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 973

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)


981
982
983
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 981

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)


992
993
994
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 992

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



1001
1002
1003
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 1001

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>)


1009
1010
1011
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 1009

def source_ports
  @source_ports
end

#stateString

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

Returns:

  • (String)


1014
1015
1016
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 1014

def state
  @state
end

#uidString

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

Returns:

  • (String)


1019
1020
1021
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 1019

def uid
  @uid
end

#update_timeString

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

Returns:

  • (String)


1024
1025
1026
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 1024

def update_time
  @update_time
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 1031

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