Skip to content

Commit

Permalink
chore(python): push cloud library docs to staging bucket for Cloud RAD (
Browse files Browse the repository at this point in the history
  • Loading branch information
parthea authored Oct 25, 2021
1 parent cb27553 commit 7fd61f8
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
4 changes: 4 additions & 0 deletions synthtool/gcp/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -262,6 +262,10 @@ def py_library(self, **kwargs) -> Path:
if Path("docs/UPGRADING.md").exists():
kwargs["include_uprading_doc"] = True

# If the directory `google/cloud` exists, add kwargs to signal that the client library is for a Cloud API
if Path("google/cloud").exists():
kwargs["is_google_cloud_api"] = True

# Assume the python-docs-samples Dockerfile is used for samples by default
if "custom_samples_dockerfile" not in kwargs:
kwargs["custom_samples_dockerfile"] = False
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,14 @@ env_vars: {

env_vars: {
key: "V2_STAGING_BUCKET"
{%- if is_google_cloud_api %}
# Push google cloud library docs to the Cloud RAD bucket `docs-staging-v2`
value: "docs-staging-v2"
{% else %}
# Push non-cloud library docs to `docs-staging-v2-staging` instead of the
# Cloud RAD bucket `docs-staging-v2`
value: "docs-staging-v2-staging"
{% endif -%}
}

# It will upload the docker image after successful builds.
Expand Down

0 comments on commit 7fd61f8

Please sign in to comment.