You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Default Compute Service Account is used if root service_account argument used to run the GKE nodes, instead of the custom service account specified. The workaround is to set the service account on a Node Pool level, however, this is not ideal.
Expected behavior
No response
Observed behavior
No response
Terraform Configuration
module"gke" {
source="terraform-google-modules/kubernetes-engine/google//modules/private-cluster"version="~> 33.1.0"project_id=var.main_projectname="${var.gke_cluster_prefix}-${var.environment}"region=var.main_regionzones=var.gke_zonesregional=var.regionalnetwork_project_id=var.host_vpc_projectnetwork=data.google_compute_network.host_vpc_network.namesubnetwork=data.google_compute_subnetwork.host_vpc_subnetwork.nameip_range_pods=var.ip_range_pods_nameip_range_services=var.ip_range_services_namemaster_ipv4_cidr_block=var.master_ipv4_cidr_blockmaster_authorized_networks=concat(
[
{
cidr_block = data.google_compute_subnetwork.host_vpc_subnetwork.ip_cidr_range
display_name ="Primary GKE Subnet CIDR"
}
],
var.additional_master_authorized_networks
)
enable_private_endpoint=truedeploy_using_private_endpoint=trueenable_private_nodes=trueadd_cluster_firewall_rules=trueadd_master_webhook_firewall_rules=trueadd_shadow_firewall_rules=truenetwork_tags=var.network_tagsremove_default_node_pool=truedeletion_protection=falsehttp_load_balancing=var.http_load_balancinghorizontal_pod_autoscaling=var.horizontal_pod_autoscalingfilestore_csi_driver=var.filestore_csi_driverdns_cache=var.dns_cachemonitoring_enable_managed_prometheus=truemonitoring_enable_observability_metrics=var.monitoring_enable_observability_metricsmonitoring_enable_observability_relay=var.monitoring_enable_observability_relaymonitoring_enabled_components=var.monitoring_enabled_componentsdatapath_provider=var.datapath_providersecurity_posture_mode="BASIC"// Enable IP masquerade in island modeconfigure_ip_masq=truenon_masquerade_cidrs=[
[forrangeindata.google_compute_subnetwork.host_vpc_subnetwork.secondary_ip_range:range.ip_cidr_rangeifrange.range_name==var.ip_range_pods_name][0],
[forrangeindata.google_compute_subnetwork.host_vpc_subnetwork.secondary_ip_range:range.ip_cidr_rangeifrange.range_name==var.ip_range_services_name][0]
]
create_service_account=falseservice_account=var.service_account_namenode_pools=var.node_poolsnode_pools_oauth_scopes=var.node_pools_oauth_scopesnode_pools_labels={
all = {
environment = var.environment
managed-by ="terraform"
}
}
node_pools_metadata={
all = {
project-id = var.main_project
}
}
node_pools_taints=var.node_pools_taintsnode_pools_tags={
all =concat(
[
"gke-node",
"${var.gke_cluster_prefix}-${var.environment}-node",
"private-cluster-node"
],
var.network_tags
)
}
}
Terraform Version
1.8
Terraform Provider Versions
Google and Google Beta provider versions are 6.16.0
Additional information
No response
The text was updated successfully, but these errors were encountered:
TL;DR
Default Compute Service Account is used if root
service_account
argument used to run the GKE nodes, instead of the custom service account specified. The workaround is to set the service account on a Node Pool level, however, this is not ideal.Expected behavior
No response
Observed behavior
No response
Terraform Configuration
Terraform Version
Terraform Provider Versions
Additional information
No response
The text was updated successfully, but these errors were encountered: