diff --git a/docs/docs/guides/tools/deploy.md b/docs/docs/guides/tools/deploy.md index 3139c59f8d0..bcdc335a1a5 100644 --- a/docs/docs/guides/tools/deploy.md +++ b/docs/docs/guides/tools/deploy.md @@ -5,10 +5,24 @@ hide_table_of_contents: true # Deploy +## Deploy to GCP + +:::note +`weave deploy` requires your machine to have `gcloud` installed and configured. `weave deploy gcp` will use pre-configured configuration when not directly specified by command line arguments. +::: + Given a Weave ref to any Weave Model you can run: ``` weave deploy gcp ``` -to deploy a gcp cloud function that serves your model. +to deploy a gcp cloud function that serves your model. The last line of the deployment will look like `Service URL: `. Visit `/docs` to interact with your model! + +Run + +``` +weave deploy gcp --help +``` + +to see all command line options. diff --git a/weave/deploy/gcp/__init__.py b/weave/deploy/gcp/__init__.py index 4f760394d9a..6dd7b016329 100644 --- a/weave/deploy/gcp/__init__.py +++ b/weave/deploy/gcp/__init__.py @@ -238,8 +238,8 @@ def deploy( """Deploy the weave application.""" enforce_login() if region is None: - region = gcloud(["config", "get", "compute/region", "--format=json"]) - if region is []: + region = gcloud(["config", "get", "functions/region", "--format=json"]) + if region == []: raise ValueError( "No default region set. Run `gcloud config set functions/region ` or set the region argument." )