Open martaver opened 4 years ago
The instance name gets generated randomly each time, and I get the same error even I specify a unique name for the instance. No idea why its trying to delete the instance when it's performing a create operation.
Got it. It was the lack of a root password.
This is kind of an unfortunate error message for an otherwise simple 'missing required field' error...
Perhaps we can improve it?
I'm self assigning this issue so that I can retest to verify if this has been resolved or is still outstanding.
I just tested the following code and it works:
const instance = new gcp.sql.DatabaseInstance(
'cluster-sql',
{
databaseVersion: 'POSTGRES_12',
region: "us-west1",
settings: {
tier: 'db-f1-micro',
activationPolicy: 'ALWAYS',
availabilityType: 'REGIONAL',
diskType: 'PD_SSD',
},
},
);
pulumi:pulumi:Stack pu_gcp_268-dev
+ ├─ gcp:sql:DatabaseInstance cluster-sql create
Resources:
+ 1 to create
Updating (dev)
Type Name Status
pulumi:pulumi:Stack pu_gcp_268-dev
+ ├─ gcp:sql:DatabaseInstance cluster-sql created (761s)
Resources:
+ 1 created
Duration: 14m9s
I did have to set a region, but got the error below:
gcp:sql:DatabaseInstance (cluster-sql):
error: sdk-v2/provider2.go:520: sdk.helper_schema: Cannot determine region: set in this resource, or set provider-level 'region' or 'zone'.: provider=google-beta@8.8.0
error: 1 error occurred:
* Cannot determine region: set in this resource, or set provider-level 'region' or 'zone'.
@martaver are you still getting the error?
Trying to deploy the following DatabaseInstance to our gcp account. Simple enough:
No matter what I do, I always get this result:
Any idea what's missing here?