I'm following the google cloud functions tutorial here: https://cloud.google.com/functions/docs/quickstart
I install google-cloud-sdk
and source both path.bash.inc
and completion.bash.inc
.
The gsutil
command step works and creates the storage bucket.
When I run gcloud beta functions deploy helloWorld --stage-bucket [BUCKET_NAME] --trigger-topic hello_world
replacing with my [BUCKET_NAME] I get usage help and the following error:
``` ERROR: (gcloud.beta) Invalid choice: 'functions'.
Valid choices are [app, auth, bigtable, compute, config, container, dataflow, dataproc, debug, deployment-manager, emulators, error-reporting, iam, init, logging, ml, organizations, projects, pubsub, service-management, source, sql, test]. ```
I'm not sure how the gcloud command works, but I can see the functions
directory in the lib/surface/
directory of the google-cloud-sdk
.
Why does gcloud beta functions
not work? How can I make it work?
Make sure you have the latest cloud SDK installed.
I got the same error and it seems I had version 137 while the latest is 152.
After running gcloud components update
it was solved.
The functions are in subscription-only beta phase right now. From Quickstart:
Beta
This is a Beta release of Google Cloud Functions. This API might be changed in backward-incompatible ways and is not subject to any SLA or deprecation policy.
Want to get advance access to the latest and greatest? Click here to become a beta tester.
The gcloud
cmd might be checking beta subscriptions. Did you subscribe?
Also make sure you have the most recent cloud SDK version.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With