google.cloud.forseti.common.gcp_type.ke_cluster module

A Kubernetes Engine Cluster object.

See: https://cloud.google.com/kubernetes-engine/docs/

class KeCluster(project_id, name, description, initial_node_count, node_config, logging_service, monitoring_service, network, cluster_ipv4_cidr, addons_config, subnetwork, node_pools, locations, enable_kubernetes_alpha, resource_labels, label_fingerprint, legacy_abac, network_policy, ip_allocation_policy, master_authorized_networks_config, maintenance_policy, zone, endpoint, initial_cluster_version, current_master_version, current_node_version, create_time, status, status_message, node_ipv4_cidr_size, instance_group_urls, current_node_count, expire_time, server_config=None, resource_full_name=None, raw_json=None)[source]

Bases: object

Represents KE Cluster resource.

__hash__()[source]

Return hash of properties. :returns: The hash of the class properties. :rtype: hash

__repr__()[source]

String representation. :returns: Json string. :rtype: str

as_dict

Return the dictionary representation of the cluster.

Returns:deserialized json object
Return type:dict
classmethod from_dict(project_id, server_config, cluster, resource_full_name=None)[source]

Returns a new ForwardingRule object from dict.

Parameters:
  • project_id (str) – The project id.
  • server_config (dict) – The ServerConfig for the cluster’s zone.
  • cluster (dict) – The KE Cluster resource.
  • resource_full_name (str) – The full resource name and ancestory.
Returns:

A new KeCluster object.

Return type:

KeCluster

static from_json(project_id, server_config, cluster, resource_full_name=None)[source]

Returns a new ForwardingRule object from json data.

Parameters:
  • project_id (str) – the project id.
  • server_config (str) – The json string representations of the ServerConfig for the cluster’s zone.
  • cluster (str) – The json string representation of the KE Cluster resource.
  • resource_full_name (str) – The full resource name and ancestory.
Returns:

A new KeCluster object.

Return type:

KeCluster