Open webpwnized opened 2 years ago
I was able to work around this by defining the network of the GKE cluster for the network parameter rather than use a generated value.
network = "projects/${var.shared_vpc_host_project}/global/networks/NETWORK"
Alternatively, this is the value which did not work for me resulting in the same error in the OP:
network = google_compute_subnetwork.shared-vpc-service-subnet.network
This has the generated value of
https://www.googleapis.com/compute/v1/projects/PROJECT_ID/global/networks/NETWORK
.
Community Note
modular-magician
user, it is either in the process of being autogenerated, or is planned to be autogenerated soon. If an issue is assigned to a user, that user is claiming responsibility for the issue. If an issue is assigned tohashibot
, a community member has claimed the issue already.Terraform Version
Terraform v1.1.2 on linux_amd64
Affected Resource(s)
Terraform Configuration Files
Debug Output
Panic Output
Error: Provider produced inconsistent final plan
When expanding the plan for module.kubernetes_module.google_container_cluster.gke_cluster to include new values learned so far during apply, provider "registry.terraform.io/hashicorp/google" produced an invalid new value for .network: was cty.StringVal("mutillidae-vpc"), but now cty.StringVal("https://www.googleapis.com/compute/v1/projects//global/networks/mutillidae-vpc").
This is a bug in the provider, which should be reported in the provider's own issue tracker.
Expected Behavior
The module would create the Kubernetes cluster, then the Kubernetes nodes
Actual Behavior
The build stopped when the panic error message appeared
Steps to Reproduce
Run terraform apply
b/300742865