feat: add auth support for GCP access tokens (#574)

Introduce choice "accesstoken" for auth_kind for modules
Introduce optional access_token string param that falls back to
  GCP_ACCESS_TOKEN env var
This commit is contained in:
Shlomo Shuck 2023-06-10 14:20:57 -04:00 committed by GitHub
parent 86e0cef208
commit 203961b045
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
173 changed files with 1181 additions and 13 deletions

View file

@ -52,6 +52,7 @@ options:
- application
- machineaccount
- serviceaccount
- accesstoken
service_account_contents:
description:
- The contents of a Service Account JSON file, either in a dictionary or as a
@ -66,6 +67,10 @@ options:
- An optional service account email address if machineaccount is selected and
the user does not wish to use the default email.
type: str
access_token:
description:
- An OAuth2 access token if credential type is accesstoken.
type: str
scopes:
description:
- Array of scopes to be used
@ -84,6 +89,8 @@ notes:
env variable.
- For authentication, you can set service_account_email using the C(GCP_SERVICE_ACCOUNT_EMAIL)
env variable.
- For authentication, you can set access_token using the C(GCP_ACCESS_TOKEN)
env variable.
- For authentication, you can set auth_kind using the C(GCP_AUTH_KIND) env variable.
- For authentication, you can set scopes using the C(GCP_SCOPES) env variable.
- Environment variables values will only be used if the playbook values are not set.