Class: Google::Apis::ContainerV1beta1::IpAllocationPolicy
- Inherits:
-
Object
- Object
- Google::Apis::ContainerV1beta1::IpAllocationPolicy
- Includes:
- Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
- Defined in:
- generated/google/apis/container_v1beta1/classes.rb,
generated/google/apis/container_v1beta1/representations.rb,
generated/google/apis/container_v1beta1/representations.rb
Overview
Configuration for controlling how IPs are allocated in the cluster.
Instance Attribute Summary collapse
-
#allow_route_overlap ⇒ Boolean
(also: #allow_route_overlap?)
If true, allow allocation of cluster CIDR ranges that overlap with certain kinds of network routes.
-
#cluster_ipv4_cidr ⇒ String
This field is deprecated, use cluster_ipv4_cidr_block.
-
#cluster_ipv4_cidr_block ⇒ String
The IP address range for the cluster pod IPs.
-
#cluster_secondary_range_name ⇒ String
The name of the secondary range to be used for the cluster CIDR block.
-
#create_subnetwork ⇒ Boolean
(also: #create_subnetwork?)
Whether a new subnetwork will be created automatically for the cluster.
-
#node_ipv4_cidr ⇒ String
This field is deprecated, use node_ipv4_cidr_block.
-
#node_ipv4_cidr_block ⇒ String
The IP address range of the instance IPs in this cluster.
-
#services_ipv4_cidr ⇒ String
This field is deprecated, use services_ipv4_cidr_block.
-
#services_ipv4_cidr_block ⇒ String
The IP address range of the services IPs in this cluster.
-
#services_secondary_range_name ⇒ String
The name of the secondary range to be used as for the services CIDR block.
-
#subnetwork_name ⇒ String
A custom subnetwork name to be used if
create_subnetwork
is true. -
#tpu_ipv4_cidr_block ⇒ String
The IP address range of the Cloud TPUs in this cluster.
-
#use_ip_aliases ⇒ Boolean
(also: #use_ip_aliases?)
Whether alias IPs will be used for pod IPs in the cluster.
-
#use_routes ⇒ Boolean
(also: #use_routes?)
Whether routes will be used for pod IPs in the cluster.
Instance Method Summary collapse
-
#initialize(**args) ⇒ IpAllocationPolicy
constructor
A new instance of IpAllocationPolicy.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ IpAllocationPolicy
Returns a new instance of IpAllocationPolicy.
1877 1878 1879 |
# File 'generated/google/apis/container_v1beta1/classes.rb', line 1877 def initialize(**args) update!(**args) end |
Instance Attribute Details
#allow_route_overlap ⇒ Boolean Also known as: allow_route_overlap?
If true, allow allocation of cluster CIDR ranges that overlap with certain
kinds of network routes. By default we do not allow cluster CIDR ranges to
intersect with any user declared routes. With allow_route_overlap == true, we
allow overlapping with CIDR ranges that are larger than the cluster CIDR range.
If this field is set to true, then cluster and services CIDRs must be fully-
specified (e.g. 10.96.0.0/14
, but not /14
), which means: 1) When
use_ip_aliases
is true, cluster_ipv4_cidr_block
and
services_ipv4_cidr_block
must be fully-specified. 2) When use_ip_aliases
is
false, cluster.cluster_ipv4_cidr
muse be fully-specified.
Corresponds to the JSON property allowRouteOverlap
1764 1765 1766 |
# File 'generated/google/apis/container_v1beta1/classes.rb', line 1764 def allow_route_overlap @allow_route_overlap end |
#cluster_ipv4_cidr ⇒ String
This field is deprecated, use cluster_ipv4_cidr_block.
Corresponds to the JSON property clusterIpv4Cidr
1770 1771 1772 |
# File 'generated/google/apis/container_v1beta1/classes.rb', line 1770 def cluster_ipv4_cidr @cluster_ipv4_cidr end |
#cluster_ipv4_cidr_block ⇒ String
The IP address range for the cluster pod IPs. If this field is set, then
cluster.cluster_ipv4_cidr
must be left blank. This field is only applicable
when use_ip_aliases
is true. Set to blank to have a range chosen with the
default size. Set to /netmask (e.g. /14
) to have a range chosen with a
specific netmask. Set to a CIDR notation (e.g. 10.96.0.0/14
) from the RFC-1918 private
networks (e.g. 10.0.0.0/8
, 172.16.0.0/12
, 192.168.0.0/16
) to pick a
specific range to use.
Corresponds to the JSON property clusterIpv4CidrBlock
1782 1783 1784 |
# File 'generated/google/apis/container_v1beta1/classes.rb', line 1782 def cluster_ipv4_cidr_block @cluster_ipv4_cidr_block end |
#cluster_secondary_range_name ⇒ String
The name of the secondary range to be used for the cluster CIDR block. The
secondary range will be used for pod IP addresses. This must be an existing
secondary range associated with the cluster subnetwork. This field is only
applicable with use_ip_aliases and create_subnetwork is false.
Corresponds to the JSON property clusterSecondaryRangeName
1790 1791 1792 |
# File 'generated/google/apis/container_v1beta1/classes.rb', line 1790 def cluster_secondary_range_name @cluster_secondary_range_name end |
#create_subnetwork ⇒ Boolean Also known as: create_subnetwork?
Whether a new subnetwork will be created automatically for the cluster. This
field is only applicable when use_ip_aliases
is true.
Corresponds to the JSON property createSubnetwork
1796 1797 1798 |
# File 'generated/google/apis/container_v1beta1/classes.rb', line 1796 def create_subnetwork @create_subnetwork end |
#node_ipv4_cidr ⇒ String
This field is deprecated, use node_ipv4_cidr_block.
Corresponds to the JSON property nodeIpv4Cidr
1802 1803 1804 |
# File 'generated/google/apis/container_v1beta1/classes.rb', line 1802 def node_ipv4_cidr @node_ipv4_cidr end |
#node_ipv4_cidr_block ⇒ String
The IP address range of the instance IPs in this cluster. This is applicable
only if create_subnetwork
is true. Set to blank to have a range chosen with
the default size. Set to /netmask (e.g. /14
) to have a range chosen with a
specific netmask. Set to a CIDR notation (e.g. 10.96.0.0/14
) from the RFC-1918 private
networks (e.g. 10.0.0.0/8
, 172.16.0.0/12
, 192.168.0.0/16
) to pick a
specific range to use.
Corresponds to the JSON property nodeIpv4CidrBlock
1813 1814 1815 |
# File 'generated/google/apis/container_v1beta1/classes.rb', line 1813 def node_ipv4_cidr_block @node_ipv4_cidr_block end |
#services_ipv4_cidr ⇒ String
This field is deprecated, use services_ipv4_cidr_block.
Corresponds to the JSON property servicesIpv4Cidr
1818 1819 1820 |
# File 'generated/google/apis/container_v1beta1/classes.rb', line 1818 def services_ipv4_cidr @services_ipv4_cidr end |
#services_ipv4_cidr_block ⇒ String
The IP address range of the services IPs in this cluster. If blank, a range
will be automatically chosen with the default size. This field is only
applicable when use_ip_aliases
is true. Set to blank to have a range chosen
with the default size. Set to /netmask (e.g. /14
) to have a range chosen
with a specific netmask. Set to a CIDR notation (e.g. 10.96.0.0/14
) from the RFC-
1918 private networks (e.g. 10.0.0.0/8
, 172.16.0.0/12
, 192.168.0.0/16
)
to pick a specific range to use.
Corresponds to the JSON property servicesIpv4CidrBlock
1830 1831 1832 |
# File 'generated/google/apis/container_v1beta1/classes.rb', line 1830 def services_ipv4_cidr_block @services_ipv4_cidr_block end |
#services_secondary_range_name ⇒ String
The name of the secondary range to be used as for the services CIDR block. The
secondary range will be used for service ClusterIPs. This must be an existing
secondary range associated with the cluster subnetwork. This field is only
applicable with use_ip_aliases and create_subnetwork is false.
Corresponds to the JSON property servicesSecondaryRangeName
1838 1839 1840 |
# File 'generated/google/apis/container_v1beta1/classes.rb', line 1838 def services_secondary_range_name @services_secondary_range_name end |
#subnetwork_name ⇒ String
A custom subnetwork name to be used if create_subnetwork
is true. If this
field is empty, then an automatic name will be chosen for the new subnetwork.
Corresponds to the JSON property subnetworkName
1844 1845 1846 |
# File 'generated/google/apis/container_v1beta1/classes.rb', line 1844 def subnetwork_name @subnetwork_name end |
#tpu_ipv4_cidr_block ⇒ String
The IP address range of the Cloud TPUs in this cluster. If unspecified, a
range will be automatically chosen with the default size. This field is only
applicable when use_ip_aliases
is true. If unspecified, the range will use
the default size. Set to /netmask (e.g. /14
) to have a range chosen with a
specific netmask. Set to a CIDR notation (e.g. 10.96.0.0/14
) from the RFC-1918 private
networks (e.g. 10.0.0.0/8
, 172.16.0.0/12
, 192.168.0.0/16
) to pick a
specific range to use. This field is deprecated, use cluster.tpu_config.
ipv4_cidr_block instead.
Corresponds to the JSON property tpuIpv4CidrBlock
1857 1858 1859 |
# File 'generated/google/apis/container_v1beta1/classes.rb', line 1857 def tpu_ipv4_cidr_block @tpu_ipv4_cidr_block end |
#use_ip_aliases ⇒ Boolean Also known as: use_ip_aliases?
Whether alias IPs will be used for pod IPs in the cluster. This is used in
conjunction with use_routes. It cannot be true if use_routes is true. If both
use_ip_aliases and use_routes are false, then the server picks the default IP
allocation mode
Corresponds to the JSON property useIpAliases
1865 1866 1867 |
# File 'generated/google/apis/container_v1beta1/classes.rb', line 1865 def use_ip_aliases @use_ip_aliases end |
#use_routes ⇒ Boolean Also known as: use_routes?
Whether routes will be used for pod IPs in the cluster. This is used in
conjunction with use_ip_aliases. It cannot be true if use_ip_aliases is true.
If both use_ip_aliases and use_routes are false, then the server picks the
default IP allocation mode
Corresponds to the JSON property useRoutes
1874 1875 1876 |
# File 'generated/google/apis/container_v1beta1/classes.rb', line 1874 def use_routes @use_routes end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
1882 1883 1884 1885 1886 1887 1888 1889 1890 1891 1892 1893 1894 1895 1896 1897 |
# File 'generated/google/apis/container_v1beta1/classes.rb', line 1882 def update!(**args) @allow_route_overlap = args[:allow_route_overlap] if args.key?(:allow_route_overlap) @cluster_ipv4_cidr = args[:cluster_ipv4_cidr] if args.key?(:cluster_ipv4_cidr) @cluster_ipv4_cidr_block = args[:cluster_ipv4_cidr_block] if args.key?(:cluster_ipv4_cidr_block) @cluster_secondary_range_name = args[:cluster_secondary_range_name] if args.key?(:cluster_secondary_range_name) @create_subnetwork = args[:create_subnetwork] if args.key?(:create_subnetwork) @node_ipv4_cidr = args[:node_ipv4_cidr] if args.key?(:node_ipv4_cidr) @node_ipv4_cidr_block = args[:node_ipv4_cidr_block] if args.key?(:node_ipv4_cidr_block) @services_ipv4_cidr = args[:services_ipv4_cidr] if args.key?(:services_ipv4_cidr) @services_ipv4_cidr_block = args[:services_ipv4_cidr_block] if args.key?(:services_ipv4_cidr_block) @services_secondary_range_name = args[:services_secondary_range_name] if args.key?(:services_secondary_range_name) @subnetwork_name = args[:subnetwork_name] if args.key?(:subnetwork_name) @tpu_ipv4_cidr_block = args[:tpu_ipv4_cidr_block] if args.key?(:tpu_ipv4_cidr_block) @use_ip_aliases = args[:use_ip_aliases] if args.key?(:use_ip_aliases) @use_routes = args[:use_routes] if args.key?(:use_routes) end |