https://pulumi.com logo
#general
Title
# general
b

best-xylophone-83824

08/22/2019, 11:56 AM
Pulimi's example to create GKE cluster involves fetching master version programmatically, but it leads to GCP API errors when new version is released:
Copy code
~ gcp:container/cluster:Cluster: (update)
        [id=gke01-london]
        [urn=urn:pulumi:gke01-london::gcp-gke::gcp:container/cluster:Cluster::gke01-london]
        [provider=urn:pulumi:gke01-london::gcp-gke::pulumi:providers:gcp::default_1_0_0_beta_1::1a4df25a-af6f-4fda-80df-2c8bd047655a]
      ~ minMasterVersion: "1.13.7-gke.19" => "1.13.7-gke.24"
      ~ nodeVersion     : "1.13.7-gke.19" => "1.13.7-gke.24"
error: Plan apply failed: 1 error occurred:
	* updating urn:pulumi:gke01-london::gcp-gke::gcp:container/cluster:Cluster::gke01-london: googleapi: Error 400: Must specify a field to update., badRequest
b

broad-dog-22463

08/22/2019, 11:58 AM
@best-xylophone-83824 I would suggest to use a named version - it’s something we have moved to do in Pulumi/examples repo because of these spurious differences :(
b

best-xylophone-83824

08/22/2019, 11:59 AM
I am changing to
Copy code
minMasterVersion: "latest",
        nodeVersion: "~", // means same as master version
and changing "description" to make update "meaningful" from GCP API point of view, lets see how it goes
Ha replace, not good 🙂
Copy code
+-gcp:container/cluster:Cluster: (replace)
        [id=gke01-london]
        [urn=urn:pulumi:gke01-london::gcp-gke::gcp:container/cluster:Cluster::gke01-london]
        [provider=urn:pulumi:gke01-london::gcp-gke::pulumi:providers:gcp::default_1_0_0_beta_1::1a4df25a-af6f-4fda-80df-2c8bd047655a]
      + description     : "xxx"
      ~ minMasterVersion: "1.13.7-gke.19" => "latest"
      ~ nodeVersion     : "1.13.7-gke.19" => "~"
b

broad-dog-22463

08/22/2019, 12:03 PM
I am actually not sure what ~ will mean for us - because that’s evaluated at the gcp level not Pulumi level
b

best-xylophone-83824

08/22/2019, 12:07 PM
turned out
~
is not supported by TF provider on cluster creation 🙂 leaving it out completely then, it seems to affect only default nodepool which gets deleted anyway
b

broad-dog-22463

08/22/2019, 12:10 PM
👌
2 Views