googleapis / google-cloud-node

Google Cloud Client Library for Node.js
https://cloud.google.com/nodejs
Apache License 2.0
2.92k stars 592 forks source link

--min-instances throws an error even with beta set #3058

Closed JosephScript closed 3 years ago

JosephScript commented 3 years ago

Apologies if this isn't the right repo to post this, but I'm having problems deploying to Cloud Run (using Nodejs) via console with the new beta --min-instances flag.

References: Cloud Run min instances: Minimize your serverless cold starts and Using minimum instances.

According to the documentation it is in Beta, so I have used the beta flag in my CLI command.

For example:

$ gcloud beta run deploy some-service-name --image some-image-name \
                                                --platform managed \
                                                --region us-central1 \
                                                --allow-unauthenticated \
                                                --vpc-connector some-vpc-connector-name \
                                                --concurrency 20 \
                                                --memory 512Mi \
                                                --cpu 2 \
                                                --min-instances 1

And I get the error:

ERROR: (gcloud.beta.run.deploy) The `--min-instances` flag is not supported on the fully managed version of Cloud Run. Specify `--platform kubernetes` or run `gcloud config set run/platform kubernetes` to work with Cloud Run for Anthos deployed on VMware.

This seems like a bug based on the documentation. I did notice the docs only reference us-west1 but I see it in beta in the GCP Console in my region. I can manually go into the Console and set the minimum to any number I want, so I know it works with our account. Is there a step I'm missing?

Thanks a bunch in advance. And we :heart: Cloud Run!

sofisl commented 3 years ago

@grayside, would you know the best way to triage/file this bug under? Thank you!

JustinBeckwith commented 3 years ago

Greetings, and thanks for the issue! We generally keep this repository for npm module specific issues. A few places where you're going to have better luck for this one are:

Both of those will get you straight to the teams that build this stuff :)