[x] All new jobs, commands, executors, parameters have descriptions
[x] Examples have been added for any significant new features
[x] README has been updated, if necessary
Motivation, issues
Fixes #49 #46 #45 #19
Description
feat: improve version handling
Allows for "latest" option and other improvements to install logic.
refactor!: Replace initialize with setup command
Previously, install and initialize were separate commands, leading to the install_and_initialize job. Using the install_and_initialize job in a workflow creates a situation where post_steps would be needed to utilize gcloud. Since following commands are expected, it's best practice to define a new job as seen in the setup example:
jobs:
use-gcp:
executor: gcp-cli/default
steps:
- gcp-cli/setup:
version: 404.0.0 # optionally pass in the GCP CLI version
All prior functionality of the initialize command is supported in the new setup command. The install command is executed as a step within the setup command, reducing the need to call install as a prerequisite.
feat: OIDC Support
Enable the use_oidc parameter on the setup command to make use of OIDC. Requires an additional environment variable called GOOGLE_PROJECT_NUMBER to be configured. Read more about GCP OIDC here: https://cloud.google.com/identity-platform/docs/web/oidc
feat: Install components
Added optional components parameter to setup and install commands. Space separate component ids to install more than one at a time. See https://cloud.google.com/sdk/docs/components for additional info.
Checklist
Motivation, issues
Fixes #49 #46 #45 #19
Description
feat: improve version handling
Allows for "latest" option and other improvements to install logic.
refactor!: Replace
initialize
withsetup
commandPreviously,
install
andinitialize
were separate commands, leading to theinstall_and_initialize
job. Using theinstall_and_initialize
job in a workflow creates a situation wherepost_steps
would be needed to utilizegcloud
. Since following commands are expected, it's best practice to define a new job as seen in the setup example:All prior functionality of the
initialize
command is supported in the newsetup
command. Theinstall
command is executed as a step within thesetup
command, reducing the need to callinstall
as a prerequisite.feat: OIDC Support
Enable the
use_oidc
parameter on thesetup
command to make use of OIDC. Requires an additional environment variable calledGOOGLE_PROJECT_NUMBER
to be configured. Read more about GCP OIDC here: https://cloud.google.com/identity-platform/docs/web/oidcfeat: Install components
Added optional
components
parameter tosetup
andinstall
commands. Space separate component ids to install more than one at a time. See https://cloud.google.com/sdk/docs/components for additional info.fix: future proof installation url being changed
The install script makes use of https://cloud.google.com/sdk/docs/downloads-versioned-archives to download requested version. For versions > 370, the URL has replaced
sdk
withcli
.