Class ContainerCluster.Builder

    • Method Detail

      • create

        @Stability(Stable)
        public static ContainerCluster.Builder create​(software.constructs.Construct scope,
                                                      String id)
        Parameters:
        scope - The scope in which to define this construct. This parameter is required.
        id - The scoped construct ID. This parameter is required.
        Returns:
        a new instance of ContainerCluster.Builder.
      • connection

        @Stability(Experimental)
        public ContainerCluster.Builder connection​(com.hashicorp.cdktf.SSHProvisionerConnection connection)
        Parameters:
        connection - This parameter is required.
        Returns:
        this
      • connection

        @Stability(Experimental)
        public ContainerCluster.Builder connection​(com.hashicorp.cdktf.WinrmProvisionerConnection connection)
        Parameters:
        connection - This parameter is required.
        Returns:
        this
      • count

        @Stability(Experimental)
        public ContainerCluster.Builder count​(Number count)
        Parameters:
        count - This parameter is required.
        Returns:
        this
      • count

        @Stability(Experimental)
        public ContainerCluster.Builder count​(com.hashicorp.cdktf.TerraformCount count)
        Parameters:
        count - This parameter is required.
        Returns:
        this
      • dependsOn

        @Stability(Experimental)
        public ContainerCluster.Builder dependsOn​(List<? extends com.hashicorp.cdktf.ITerraformDependable> dependsOn)
        Parameters:
        dependsOn - This parameter is required.
        Returns:
        this
      • forEach

        @Stability(Experimental)
        public ContainerCluster.Builder forEach​(com.hashicorp.cdktf.ITerraformIterator forEach)
        Parameters:
        forEach - This parameter is required.
        Returns:
        this
      • lifecycle

        @Stability(Experimental)
        public ContainerCluster.Builder lifecycle​(com.hashicorp.cdktf.TerraformResourceLifecycle lifecycle)
        Parameters:
        lifecycle - This parameter is required.
        Returns:
        this
      • provider

        @Stability(Experimental)
        public ContainerCluster.Builder provider​(com.hashicorp.cdktf.TerraformProvider provider)
        Parameters:
        provider - This parameter is required.
        Returns:
        this
      • provisioners

        @Stability(Experimental)
        public ContainerCluster.Builder provisioners​(List<? extends Object> provisioners)
        Parameters:
        provisioners - This parameter is required.
        Returns:
        this
      • name

        @Stability(Stable)
        public ContainerCluster.Builder name​(String name)
        The name of the cluster, unique within the project and location.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#name ContainerCluster#name}

        Parameters:
        name - The name of the cluster, unique within the project and location. This parameter is required.
        Returns:
        this
      • addonsConfig

        @Stability(Stable)
        public ContainerCluster.Builder addonsConfig​(ContainerClusterAddonsConfig addonsConfig)
        addons_config block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#addons_config ContainerCluster#addons_config}

        Parameters:
        addonsConfig - addons_config block. This parameter is required.
        Returns:
        this
      • allowNetAdmin

        @Stability(Stable)
        public ContainerCluster.Builder allowNetAdmin​(Boolean allowNetAdmin)
        Enable NET_ADMIN for this cluster.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#allow_net_admin ContainerCluster#allow_net_admin}

        Parameters:
        allowNetAdmin - Enable NET_ADMIN for this cluster. This parameter is required.
        Returns:
        this
      • allowNetAdmin

        @Stability(Stable)
        public ContainerCluster.Builder allowNetAdmin​(com.hashicorp.cdktf.IResolvable allowNetAdmin)
        Enable NET_ADMIN for this cluster.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#allow_net_admin ContainerCluster#allow_net_admin}

        Parameters:
        allowNetAdmin - Enable NET_ADMIN for this cluster. This parameter is required.
        Returns:
        this
      • authenticatorGroupsConfig

        @Stability(Stable)
        public ContainerCluster.Builder authenticatorGroupsConfig​(ContainerClusterAuthenticatorGroupsConfig authenticatorGroupsConfig)
        authenticator_groups_config block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#authenticator_groups_config ContainerCluster#authenticator_groups_config}

        Parameters:
        authenticatorGroupsConfig - authenticator_groups_config block. This parameter is required.
        Returns:
        this
      • binaryAuthorization

        @Stability(Stable)
        public ContainerCluster.Builder binaryAuthorization​(ContainerClusterBinaryAuthorization binaryAuthorization)
        binary_authorization block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#binary_authorization ContainerCluster#binary_authorization}

        Parameters:
        binaryAuthorization - binary_authorization block. This parameter is required.
        Returns:
        this
      • clusterAutoscaling

        @Stability(Stable)
        public ContainerCluster.Builder clusterAutoscaling​(ContainerClusterClusterAutoscaling clusterAutoscaling)
        cluster_autoscaling block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#cluster_autoscaling ContainerCluster#cluster_autoscaling}

        Parameters:
        clusterAutoscaling - cluster_autoscaling block. This parameter is required.
        Returns:
        this
      • clusterIpv4Cidr

        @Stability(Stable)
        public ContainerCluster.Builder clusterIpv4Cidr​(String clusterIpv4Cidr)
        The IP address range of the Kubernetes pods in this cluster in CIDR notation (e.g. 10.96.0.0/14). Leave blank to have one automatically chosen or specify a /14 block in 10.0.0.0/8. This field will only work for routes-based clusters, where ip_allocation_policy is not defined.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#cluster_ipv4_cidr ContainerCluster#cluster_ipv4_cidr}

        Parameters:
        clusterIpv4Cidr - The IP address range of the Kubernetes pods in this cluster in CIDR notation (e.g. 10.96.0.0/14). Leave blank to have one automatically chosen or specify a /14 block in 10.0.0.0/8. This field will only work for routes-based clusters, where ip_allocation_policy is not defined. This parameter is required.
        Returns:
        this
      • confidentialNodes

        @Stability(Stable)
        public ContainerCluster.Builder confidentialNodes​(ContainerClusterConfidentialNodes confidentialNodes)
        confidential_nodes block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#confidential_nodes ContainerCluster#confidential_nodes}

        Parameters:
        confidentialNodes - confidential_nodes block. This parameter is required.
        Returns:
        this
      • costManagementConfig

        @Stability(Stable)
        public ContainerCluster.Builder costManagementConfig​(ContainerClusterCostManagementConfig costManagementConfig)
        cost_management_config block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#cost_management_config ContainerCluster#cost_management_config}

        Parameters:
        costManagementConfig - cost_management_config block. This parameter is required.
        Returns:
        this
      • databaseEncryption

        @Stability(Stable)
        public ContainerCluster.Builder databaseEncryption​(ContainerClusterDatabaseEncryption databaseEncryption)
        database_encryption block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#database_encryption ContainerCluster#database_encryption}

        Parameters:
        databaseEncryption - database_encryption block. This parameter is required.
        Returns:
        this
      • datapathProvider

        @Stability(Stable)
        public ContainerCluster.Builder datapathProvider​(String datapathProvider)
        The desired datapath provider for this cluster. By default, uses the IPTables-based kube-proxy implementation.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#datapath_provider ContainerCluster#datapath_provider}

        Parameters:
        datapathProvider - The desired datapath provider for this cluster. By default, uses the IPTables-based kube-proxy implementation. This parameter is required.
        Returns:
        this
      • defaultMaxPodsPerNode

        @Stability(Stable)
        public ContainerCluster.Builder defaultMaxPodsPerNode​(Number defaultMaxPodsPerNode)
        The default maximum number of pods per node in this cluster.

        This doesn't work on "routes-based" clusters, clusters that don't have IP Aliasing enabled. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#default_max_pods_per_node ContainerCluster#default_max_pods_per_node}

        Parameters:
        defaultMaxPodsPerNode - The default maximum number of pods per node in this cluster. This parameter is required.
        Returns:
        this
      • defaultSnatStatus

        @Stability(Stable)
        public ContainerCluster.Builder defaultSnatStatus​(ContainerClusterDefaultSnatStatus defaultSnatStatus)
        default_snat_status block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#default_snat_status ContainerCluster#default_snat_status}

        Parameters:
        defaultSnatStatus - default_snat_status block. This parameter is required.
        Returns:
        this
      • deletionProtection

        @Stability(Stable)
        public ContainerCluster.Builder deletionProtection​(Boolean deletionProtection)
        When the field is set to true or unset in Terraform state, a terraform apply or terraform destroy that would delete the cluster will fail.

        When the field is set to false, deleting the cluster is allowed. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#deletion_protection ContainerCluster#deletion_protection}

        Parameters:
        deletionProtection - When the field is set to true or unset in Terraform state, a terraform apply or terraform destroy that would delete the cluster will fail. This parameter is required.
        Returns:
        this
      • deletionProtection

        @Stability(Stable)
        public ContainerCluster.Builder deletionProtection​(com.hashicorp.cdktf.IResolvable deletionProtection)
        When the field is set to true or unset in Terraform state, a terraform apply or terraform destroy that would delete the cluster will fail.

        When the field is set to false, deleting the cluster is allowed. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#deletion_protection ContainerCluster#deletion_protection}

        Parameters:
        deletionProtection - When the field is set to true or unset in Terraform state, a terraform apply or terraform destroy that would delete the cluster will fail. This parameter is required.
        Returns:
        this
      • description

        @Stability(Stable)
        public ContainerCluster.Builder description​(String description)
        Description of the cluster.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#description ContainerCluster#description}

        Parameters:
        description - Description of the cluster. This parameter is required.
        Returns:
        this
      • dnsConfig

        @Stability(Stable)
        public ContainerCluster.Builder dnsConfig​(ContainerClusterDnsConfig dnsConfig)
        dns_config block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#dns_config ContainerCluster#dns_config}

        Parameters:
        dnsConfig - dns_config block. This parameter is required.
        Returns:
        this
      • enableAutopilot

        @Stability(Stable)
        public ContainerCluster.Builder enableAutopilot​(Boolean enableAutopilot)
        Enable Autopilot for this cluster.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#enable_autopilot ContainerCluster#enable_autopilot}

        Parameters:
        enableAutopilot - Enable Autopilot for this cluster. This parameter is required.
        Returns:
        this
      • enableAutopilot

        @Stability(Stable)
        public ContainerCluster.Builder enableAutopilot​(com.hashicorp.cdktf.IResolvable enableAutopilot)
        Enable Autopilot for this cluster.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#enable_autopilot ContainerCluster#enable_autopilot}

        Parameters:
        enableAutopilot - Enable Autopilot for this cluster. This parameter is required.
        Returns:
        this
      • enableCiliumClusterwideNetworkPolicy

        @Stability(Stable)
        public ContainerCluster.Builder enableCiliumClusterwideNetworkPolicy​(Boolean enableCiliumClusterwideNetworkPolicy)
        Whether Cilium cluster-wide network policy is enabled on this cluster.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#enable_cilium_clusterwide_network_policy ContainerCluster#enable_cilium_clusterwide_network_policy}

        Parameters:
        enableCiliumClusterwideNetworkPolicy - Whether Cilium cluster-wide network policy is enabled on this cluster. This parameter is required.
        Returns:
        this
      • enableCiliumClusterwideNetworkPolicy

        @Stability(Stable)
        public ContainerCluster.Builder enableCiliumClusterwideNetworkPolicy​(com.hashicorp.cdktf.IResolvable enableCiliumClusterwideNetworkPolicy)
        Whether Cilium cluster-wide network policy is enabled on this cluster.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#enable_cilium_clusterwide_network_policy ContainerCluster#enable_cilium_clusterwide_network_policy}

        Parameters:
        enableCiliumClusterwideNetworkPolicy - Whether Cilium cluster-wide network policy is enabled on this cluster. This parameter is required.
        Returns:
        this
      • enableIntranodeVisibility

        @Stability(Stable)
        public ContainerCluster.Builder enableIntranodeVisibility​(Boolean enableIntranodeVisibility)
        Whether Intra-node visibility is enabled for this cluster.

        This makes same node pod to pod traffic visible for VPC network. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#enable_intranode_visibility ContainerCluster#enable_intranode_visibility}

        Parameters:
        enableIntranodeVisibility - Whether Intra-node visibility is enabled for this cluster. This parameter is required.
        Returns:
        this
      • enableIntranodeVisibility

        @Stability(Stable)
        public ContainerCluster.Builder enableIntranodeVisibility​(com.hashicorp.cdktf.IResolvable enableIntranodeVisibility)
        Whether Intra-node visibility is enabled for this cluster.

        This makes same node pod to pod traffic visible for VPC network. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#enable_intranode_visibility ContainerCluster#enable_intranode_visibility}

        Parameters:
        enableIntranodeVisibility - Whether Intra-node visibility is enabled for this cluster. This parameter is required.
        Returns:
        this
      • enableK8SBetaApis

        @Stability(Stable)
        public ContainerCluster.Builder enableK8SBetaApis​(ContainerClusterEnableK8SBetaApis enableK8SBetaApis)
        enable_k8s_beta_apis block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#enable_k8s_beta_apis ContainerCluster#enable_k8s_beta_apis}

        Parameters:
        enableK8SBetaApis - enable_k8s_beta_apis block. This parameter is required.
        Returns:
        this
      • enableKubernetesAlpha

        @Stability(Stable)
        public ContainerCluster.Builder enableKubernetesAlpha​(Boolean enableKubernetesAlpha)
        Whether to enable Kubernetes Alpha features for this cluster.

        Note that when this option is enabled, the cluster cannot be upgraded and will be automatically deleted after 30 days. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#enable_kubernetes_alpha ContainerCluster#enable_kubernetes_alpha}

        Parameters:
        enableKubernetesAlpha - Whether to enable Kubernetes Alpha features for this cluster. This parameter is required.
        Returns:
        this
      • enableKubernetesAlpha

        @Stability(Stable)
        public ContainerCluster.Builder enableKubernetesAlpha​(com.hashicorp.cdktf.IResolvable enableKubernetesAlpha)
        Whether to enable Kubernetes Alpha features for this cluster.

        Note that when this option is enabled, the cluster cannot be upgraded and will be automatically deleted after 30 days. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#enable_kubernetes_alpha ContainerCluster#enable_kubernetes_alpha}

        Parameters:
        enableKubernetesAlpha - Whether to enable Kubernetes Alpha features for this cluster. This parameter is required.
        Returns:
        this
      • enableL4IlbSubsetting

        @Stability(Stable)
        public ContainerCluster.Builder enableL4IlbSubsetting​(Boolean enableL4IlbSubsetting)
        Whether L4ILB Subsetting is enabled for this cluster.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#enable_l4_ilb_subsetting ContainerCluster#enable_l4_ilb_subsetting}

        Parameters:
        enableL4IlbSubsetting - Whether L4ILB Subsetting is enabled for this cluster. This parameter is required.
        Returns:
        this
      • enableL4IlbSubsetting

        @Stability(Stable)
        public ContainerCluster.Builder enableL4IlbSubsetting​(com.hashicorp.cdktf.IResolvable enableL4IlbSubsetting)
        Whether L4ILB Subsetting is enabled for this cluster.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#enable_l4_ilb_subsetting ContainerCluster#enable_l4_ilb_subsetting}

        Parameters:
        enableL4IlbSubsetting - Whether L4ILB Subsetting is enabled for this cluster. This parameter is required.
        Returns:
        this
      • enableLegacyAbac

        @Stability(Stable)
        public ContainerCluster.Builder enableLegacyAbac​(Boolean enableLegacyAbac)
        Whether the ABAC authorizer is enabled for this cluster.

        When enabled, identities in the system, including service accounts, nodes, and controllers, will have statically granted permissions beyond those provided by the RBAC configuration or IAM. Defaults to false. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#enable_legacy_abac ContainerCluster#enable_legacy_abac}

        Parameters:
        enableLegacyAbac - Whether the ABAC authorizer is enabled for this cluster. This parameter is required.
        Returns:
        this
      • enableLegacyAbac

        @Stability(Stable)
        public ContainerCluster.Builder enableLegacyAbac​(com.hashicorp.cdktf.IResolvable enableLegacyAbac)
        Whether the ABAC authorizer is enabled for this cluster.

        When enabled, identities in the system, including service accounts, nodes, and controllers, will have statically granted permissions beyond those provided by the RBAC configuration or IAM. Defaults to false. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#enable_legacy_abac ContainerCluster#enable_legacy_abac}

        Parameters:
        enableLegacyAbac - Whether the ABAC authorizer is enabled for this cluster. This parameter is required.
        Returns:
        this
      • enableMultiNetworking

        @Stability(Stable)
        public ContainerCluster.Builder enableMultiNetworking​(Boolean enableMultiNetworking)
        Whether multi-networking is enabled for this cluster.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#enable_multi_networking ContainerCluster#enable_multi_networking}

        Parameters:
        enableMultiNetworking - Whether multi-networking is enabled for this cluster. This parameter is required.
        Returns:
        this
      • enableMultiNetworking

        @Stability(Stable)
        public ContainerCluster.Builder enableMultiNetworking​(com.hashicorp.cdktf.IResolvable enableMultiNetworking)
        Whether multi-networking is enabled for this cluster.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#enable_multi_networking ContainerCluster#enable_multi_networking}

        Parameters:
        enableMultiNetworking - Whether multi-networking is enabled for this cluster. This parameter is required.
        Returns:
        this
      • enableShieldedNodes

        @Stability(Stable)
        public ContainerCluster.Builder enableShieldedNodes​(Boolean enableShieldedNodes)
        Enable Shielded Nodes features on all nodes in this cluster. Defaults to true.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#enable_shielded_nodes ContainerCluster#enable_shielded_nodes}

        Parameters:
        enableShieldedNodes - Enable Shielded Nodes features on all nodes in this cluster. Defaults to true. This parameter is required.
        Returns:
        this
      • enableShieldedNodes

        @Stability(Stable)
        public ContainerCluster.Builder enableShieldedNodes​(com.hashicorp.cdktf.IResolvable enableShieldedNodes)
        Enable Shielded Nodes features on all nodes in this cluster. Defaults to true.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#enable_shielded_nodes ContainerCluster#enable_shielded_nodes}

        Parameters:
        enableShieldedNodes - Enable Shielded Nodes features on all nodes in this cluster. Defaults to true. This parameter is required.
        Returns:
        this
      • enableTpu

        @Stability(Stable)
        public ContainerCluster.Builder enableTpu​(Boolean enableTpu)
        Whether to enable Cloud TPU resources in this cluster.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#enable_tpu ContainerCluster#enable_tpu}

        Parameters:
        enableTpu - Whether to enable Cloud TPU resources in this cluster. This parameter is required.
        Returns:
        this
      • enableTpu

        @Stability(Stable)
        public ContainerCluster.Builder enableTpu​(com.hashicorp.cdktf.IResolvable enableTpu)
        Whether to enable Cloud TPU resources in this cluster.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#enable_tpu ContainerCluster#enable_tpu}

        Parameters:
        enableTpu - Whether to enable Cloud TPU resources in this cluster. This parameter is required.
        Returns:
        this
      • fleet

        @Stability(Stable)
        public ContainerCluster.Builder fleet​(ContainerClusterFleet fleet)
        fleet block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#fleet ContainerCluster#fleet}

        Parameters:
        fleet - fleet block. This parameter is required.
        Returns:
        this
      • gatewayApiConfig

        @Stability(Stable)
        public ContainerCluster.Builder gatewayApiConfig​(ContainerClusterGatewayApiConfig gatewayApiConfig)
        gateway_api_config block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#gateway_api_config ContainerCluster#gateway_api_config}

        Parameters:
        gatewayApiConfig - gateway_api_config block. This parameter is required.
        Returns:
        this
      • id

        @Stability(Stable)
        public ContainerCluster.Builder id​(String id)
        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#id ContainerCluster#id}.

        Please be aware that the id field is automatically added to all resources in Terraform providers using a Terraform provider SDK version below 2. If you experience problems setting this value it might not be settable. Please take a look at the provider documentation to ensure it should be settable.

        Parameters:
        id - Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#id ContainerCluster#id}. This parameter is required.
        Returns:
        this
      • identityServiceConfig

        @Stability(Stable)
        public ContainerCluster.Builder identityServiceConfig​(ContainerClusterIdentityServiceConfig identityServiceConfig)
        identity_service_config block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#identity_service_config ContainerCluster#identity_service_config}

        Parameters:
        identityServiceConfig - identity_service_config block. This parameter is required.
        Returns:
        this
      • initialNodeCount

        @Stability(Stable)
        public ContainerCluster.Builder initialNodeCount​(Number initialNodeCount)
        The number of nodes to create in this cluster's default node pool.

        In regional or multi-zonal clusters, this is the number of nodes per zone. Must be set if node_pool is not set. If you're using google_container_node_pool objects with no default node pool, you'll need to set this to a value of at least 1, alongside setting remove_default_node_pool to true. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#initial_node_count ContainerCluster#initial_node_count}

        Parameters:
        initialNodeCount - The number of nodes to create in this cluster's default node pool. This parameter is required.
        Returns:
        this
      • ipAllocationPolicy

        @Stability(Stable)
        public ContainerCluster.Builder ipAllocationPolicy​(ContainerClusterIpAllocationPolicy ipAllocationPolicy)
        ip_allocation_policy block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#ip_allocation_policy ContainerCluster#ip_allocation_policy}

        Parameters:
        ipAllocationPolicy - ip_allocation_policy block. This parameter is required.
        Returns:
        this
      • location

        @Stability(Stable)
        public ContainerCluster.Builder location​(String location)
        The location (region or zone) in which the cluster master will be created, as well as the default node location.

        If you specify a zone (such as us-central1-a), the cluster will be a zonal cluster with a single cluster master. If you specify a region (such as us-west1), the cluster will be a regional cluster with multiple masters spread across zones in the region, and with default node locations in those zones as well. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#location ContainerCluster#location}

        Parameters:
        location - The location (region or zone) in which the cluster master will be created, as well as the default node location. This parameter is required.
        Returns:
        this
      • loggingConfig

        @Stability(Stable)
        public ContainerCluster.Builder loggingConfig​(ContainerClusterLoggingConfig loggingConfig)
        logging_config block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#logging_config ContainerCluster#logging_config}

        Parameters:
        loggingConfig - logging_config block. This parameter is required.
        Returns:
        this
      • loggingService

        @Stability(Stable)
        public ContainerCluster.Builder loggingService​(String loggingService)
        The logging service that the cluster should write logs to.

        Available options include logging.googleapis.com(Legacy Stackdriver), logging.googleapis.com/kubernetes(Stackdriver Kubernetes Engine Logging), and none. Defaults to logging.googleapis.com/kubernetes. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#logging_service ContainerCluster#logging_service}

        Parameters:
        loggingService - The logging service that the cluster should write logs to. This parameter is required.
        Returns:
        this
      • maintenancePolicy

        @Stability(Stable)
        public ContainerCluster.Builder maintenancePolicy​(ContainerClusterMaintenancePolicy maintenancePolicy)
        maintenance_policy block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#maintenance_policy ContainerCluster#maintenance_policy}

        Parameters:
        maintenancePolicy - maintenance_policy block. This parameter is required.
        Returns:
        this
      • masterAuth

        @Stability(Stable)
        public ContainerCluster.Builder masterAuth​(ContainerClusterMasterAuth masterAuth)
        master_auth block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#master_auth ContainerCluster#master_auth}

        Parameters:
        masterAuth - master_auth block. This parameter is required.
        Returns:
        this
      • masterAuthorizedNetworksConfig

        @Stability(Stable)
        public ContainerCluster.Builder masterAuthorizedNetworksConfig​(ContainerClusterMasterAuthorizedNetworksConfig masterAuthorizedNetworksConfig)
        master_authorized_networks_config block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#master_authorized_networks_config ContainerCluster#master_authorized_networks_config}

        Parameters:
        masterAuthorizedNetworksConfig - master_authorized_networks_config block. This parameter is required.
        Returns:
        this
      • meshCertificates

        @Stability(Stable)
        public ContainerCluster.Builder meshCertificates​(ContainerClusterMeshCertificates meshCertificates)
        mesh_certificates block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#mesh_certificates ContainerCluster#mesh_certificates}

        Parameters:
        meshCertificates - mesh_certificates block. This parameter is required.
        Returns:
        this
      • minMasterVersion

        @Stability(Stable)
        public ContainerCluster.Builder minMasterVersion​(String minMasterVersion)
        The minimum version of the master.

        GKE will auto-update the master to new versions, so this does not guarantee the current master version--use the read-only master_version field to obtain that. If unset, the cluster's version will be set by GKE to the version of the most recent official release (which is not necessarily the latest version). Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#min_master_version ContainerCluster#min_master_version}

        Parameters:
        minMasterVersion - The minimum version of the master. This parameter is required.
        Returns:
        this
      • monitoringConfig

        @Stability(Stable)
        public ContainerCluster.Builder monitoringConfig​(ContainerClusterMonitoringConfig monitoringConfig)
        monitoring_config block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#monitoring_config ContainerCluster#monitoring_config}

        Parameters:
        monitoringConfig - monitoring_config block. This parameter is required.
        Returns:
        this
      • monitoringService

        @Stability(Stable)
        public ContainerCluster.Builder monitoringService​(String monitoringService)
        The monitoring service that the cluster should write metrics to.

        Automatically send metrics from pods in the cluster to the Google Cloud Monitoring API. VM metrics will be collected by Google Compute Engine regardless of this setting Available options include monitoring.googleapis.com(Legacy Stackdriver), monitoring.googleapis.com/kubernetes(Stackdriver Kubernetes Engine Monitoring), and none. Defaults to monitoring.googleapis.com/kubernetes. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#monitoring_service ContainerCluster#monitoring_service}

        Parameters:
        monitoringService - The monitoring service that the cluster should write metrics to. This parameter is required.
        Returns:
        this
      • network

        @Stability(Stable)
        public ContainerCluster.Builder network​(String network)
        The name or self_link of the Google Compute Engine network to which the cluster is connected.

        For Shared VPC, set this to the self link of the shared network. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#network ContainerCluster#network}

        Parameters:
        network - The name or self_link of the Google Compute Engine network to which the cluster is connected. This parameter is required.
        Returns:
        this
      • networkingMode

        @Stability(Stable)
        public ContainerCluster.Builder networkingMode​(String networkingMode)
        Determines whether alias IPs or routes will be used for pod IPs in the cluster.

        Defaults to VPC_NATIVE for new clusters. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#networking_mode ContainerCluster#networking_mode}

        Parameters:
        networkingMode - Determines whether alias IPs or routes will be used for pod IPs in the cluster. This parameter is required.
        Returns:
        this
      • networkPolicy

        @Stability(Stable)
        public ContainerCluster.Builder networkPolicy​(ContainerClusterNetworkPolicy networkPolicy)
        network_policy block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#network_policy ContainerCluster#network_policy}

        Parameters:
        networkPolicy - network_policy block. This parameter is required.
        Returns:
        this
      • nodeConfig

        @Stability(Stable)
        public ContainerCluster.Builder nodeConfig​(ContainerClusterNodeConfig nodeConfig)
        node_config block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#node_config ContainerCluster#node_config}

        Parameters:
        nodeConfig - node_config block. This parameter is required.
        Returns:
        this
      • nodeLocations

        @Stability(Stable)
        public ContainerCluster.Builder nodeLocations​(List<String> nodeLocations)
        The list of zones in which the cluster's nodes are located.

        Nodes must be in the region of their regional cluster or in the same region as their cluster's zone for zonal clusters. If this is specified for a zonal cluster, omit the cluster's zone. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#node_locations ContainerCluster#node_locations}

        Parameters:
        nodeLocations - The list of zones in which the cluster's nodes are located. This parameter is required.
        Returns:
        this
      • nodePool

        @Stability(Stable)
        public ContainerCluster.Builder nodePool​(com.hashicorp.cdktf.IResolvable nodePool)
        node_pool block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#node_pool ContainerCluster#node_pool}

        Parameters:
        nodePool - node_pool block. This parameter is required.
        Returns:
        this
      • nodePool

        @Stability(Stable)
        public ContainerCluster.Builder nodePool​(List<? extends ContainerClusterNodePool> nodePool)
        node_pool block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#node_pool ContainerCluster#node_pool}

        Parameters:
        nodePool - node_pool block. This parameter is required.
        Returns:
        this
      • nodePoolAutoConfig

        @Stability(Stable)
        public ContainerCluster.Builder nodePoolAutoConfig​(ContainerClusterNodePoolAutoConfig nodePoolAutoConfig)
        node_pool_auto_config block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#node_pool_auto_config ContainerCluster#node_pool_auto_config}

        Parameters:
        nodePoolAutoConfig - node_pool_auto_config block. This parameter is required.
        Returns:
        this
      • nodePoolDefaults

        @Stability(Stable)
        public ContainerCluster.Builder nodePoolDefaults​(ContainerClusterNodePoolDefaults nodePoolDefaults)
        node_pool_defaults block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#node_pool_defaults ContainerCluster#node_pool_defaults}

        Parameters:
        nodePoolDefaults - node_pool_defaults block. This parameter is required.
        Returns:
        this
      • nodeVersion

        @Stability(Stable)
        public ContainerCluster.Builder nodeVersion​(String nodeVersion)
        The Kubernetes version on the nodes.

        Must either be unset or set to the same value as min_master_version on create. Defaults to the default version set by GKE which is not necessarily the latest version. This only affects nodes in the default node pool. While a fuzzy version can be specified, it's recommended that you specify explicit versions as Terraform will see spurious diffs when fuzzy versions are used. See the google_container_engine_versions data source's version_prefix field to approximate fuzzy versions in a Terraform-compatible way. To update nodes in other node pools, use the version attribute on the node pool. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#node_version ContainerCluster#node_version}

        Parameters:
        nodeVersion - The Kubernetes version on the nodes. This parameter is required.
        Returns:
        this
      • notificationConfig

        @Stability(Stable)
        public ContainerCluster.Builder notificationConfig​(ContainerClusterNotificationConfig notificationConfig)
        notification_config block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#notification_config ContainerCluster#notification_config}

        Parameters:
        notificationConfig - notification_config block. This parameter is required.
        Returns:
        this
      • privateClusterConfig

        @Stability(Stable)
        public ContainerCluster.Builder privateClusterConfig​(ContainerClusterPrivateClusterConfig privateClusterConfig)
        private_cluster_config block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#private_cluster_config ContainerCluster#private_cluster_config}

        Parameters:
        privateClusterConfig - private_cluster_config block. This parameter is required.
        Returns:
        this
      • privateIpv6GoogleAccess

        @Stability(Stable)
        public ContainerCluster.Builder privateIpv6GoogleAccess​(String privateIpv6GoogleAccess)
        The desired state of IPv6 connectivity to Google Services.

        By default, no private IPv6 access to or from Google Services (all access will be via IPv4). Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#private_ipv6_google_access ContainerCluster#private_ipv6_google_access}

        Parameters:
        privateIpv6GoogleAccess - The desired state of IPv6 connectivity to Google Services. This parameter is required.
        Returns:
        this
      • project

        @Stability(Stable)
        public ContainerCluster.Builder project​(String project)
        The ID of the project in which the resource belongs.

        If it is not provided, the provider project is used. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#project ContainerCluster#project}

        Parameters:
        project - The ID of the project in which the resource belongs. This parameter is required.
        Returns:
        this
      • releaseChannel

        @Stability(Stable)
        public ContainerCluster.Builder releaseChannel​(ContainerClusterReleaseChannel releaseChannel)
        release_channel block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#release_channel ContainerCluster#release_channel}

        Parameters:
        releaseChannel - release_channel block. This parameter is required.
        Returns:
        this
      • removeDefaultNodePool

        @Stability(Stable)
        public ContainerCluster.Builder removeDefaultNodePool​(Boolean removeDefaultNodePool)
        If true, deletes the default node pool upon cluster creation.

        If you're using google_container_node_pool resources with no default node pool, this should be set to true, alongside setting initial_node_count to at least 1. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#remove_default_node_pool ContainerCluster#remove_default_node_pool}

        Parameters:
        removeDefaultNodePool - If true, deletes the default node pool upon cluster creation. This parameter is required.
        Returns:
        this
      • removeDefaultNodePool

        @Stability(Stable)
        public ContainerCluster.Builder removeDefaultNodePool​(com.hashicorp.cdktf.IResolvable removeDefaultNodePool)
        If true, deletes the default node pool upon cluster creation.

        If you're using google_container_node_pool resources with no default node pool, this should be set to true, alongside setting initial_node_count to at least 1. Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#remove_default_node_pool ContainerCluster#remove_default_node_pool}

        Parameters:
        removeDefaultNodePool - If true, deletes the default node pool upon cluster creation. This parameter is required.
        Returns:
        this
      • resourceLabels

        @Stability(Stable)
        public ContainerCluster.Builder resourceLabels​(Map<String,​String> resourceLabels)
        The GCE resource labels (a map of key/value pairs) to be applied to the cluster.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#resource_labels ContainerCluster#resource_labels}

        Parameters:
        resourceLabels - The GCE resource labels (a map of key/value pairs) to be applied to the cluster. This parameter is required.
        Returns:
        this
      • resourceUsageExportConfig

        @Stability(Stable)
        public ContainerCluster.Builder resourceUsageExportConfig​(ContainerClusterResourceUsageExportConfig resourceUsageExportConfig)
        resource_usage_export_config block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#resource_usage_export_config ContainerCluster#resource_usage_export_config}

        Parameters:
        resourceUsageExportConfig - resource_usage_export_config block. This parameter is required.
        Returns:
        this
      • securityPostureConfig

        @Stability(Stable)
        public ContainerCluster.Builder securityPostureConfig​(ContainerClusterSecurityPostureConfig securityPostureConfig)
        security_posture_config block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#security_posture_config ContainerCluster#security_posture_config}

        Parameters:
        securityPostureConfig - security_posture_config block. This parameter is required.
        Returns:
        this
      • serviceExternalIpsConfig

        @Stability(Stable)
        public ContainerCluster.Builder serviceExternalIpsConfig​(ContainerClusterServiceExternalIpsConfig serviceExternalIpsConfig)
        service_external_ips_config block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#service_external_ips_config ContainerCluster#service_external_ips_config}

        Parameters:
        serviceExternalIpsConfig - service_external_ips_config block. This parameter is required.
        Returns:
        this
      • subnetwork

        @Stability(Stable)
        public ContainerCluster.Builder subnetwork​(String subnetwork)
        The name or self_link of the Google Compute Engine subnetwork in which the cluster's instances are launched.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#subnetwork ContainerCluster#subnetwork}

        Parameters:
        subnetwork - The name or self_link of the Google Compute Engine subnetwork in which the cluster's instances are launched. This parameter is required.
        Returns:
        this
      • timeouts

        @Stability(Stable)
        public ContainerCluster.Builder timeouts​(ContainerClusterTimeouts timeouts)
        timeouts block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#timeouts ContainerCluster#timeouts}

        Parameters:
        timeouts - timeouts block. This parameter is required.
        Returns:
        this
      • verticalPodAutoscaling

        @Stability(Stable)
        public ContainerCluster.Builder verticalPodAutoscaling​(ContainerClusterVerticalPodAutoscaling verticalPodAutoscaling)
        vertical_pod_autoscaling block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#vertical_pod_autoscaling ContainerCluster#vertical_pod_autoscaling}

        Parameters:
        verticalPodAutoscaling - vertical_pod_autoscaling block. This parameter is required.
        Returns:
        this
      • workloadIdentityConfig

        @Stability(Stable)
        public ContainerCluster.Builder workloadIdentityConfig​(ContainerClusterWorkloadIdentityConfig workloadIdentityConfig)
        workload_identity_config block.

        Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/google/5.43.1/docs/resources/container_cluster#workload_identity_config ContainerCluster#workload_identity_config}

        Parameters:
        workloadIdentityConfig - workload_identity_config block. This parameter is required.
        Returns:
        this