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.



996
997
998
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 996

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)


908
909
910
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 908

def action
  @action
end

#create_timeString

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

Returns:

  • (String)


913
914
915
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 913

def create_time
  @create_time
end

#descriptionString

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

Returns:

  • (String)


918
919
920
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 918

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



928
929
930
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 928

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


936
937
938
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 936

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)


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

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)


951
952
953
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 951

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)


962
963
964
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 962

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



971
972
973
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 971

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


979
980
981
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 979

def source_ports
  @source_ports
end

#stateString

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

Returns:

  • (String)


984
985
986
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 984

def state
  @state
end

#uidString

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

Returns:

  • (String)


989
990
991
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 989

def uid
  @uid
end

#update_timeString

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

Returns:

  • (String)


994
995
996
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 994

def update_time
  @update_time
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
# File 'lib/google/apis/vmwareengine_v1/classes.rb', line 1001

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