Skip to content

Commit

Permalink
gcp - pass project id into credentials constructor (#6608)
Browse files Browse the repository at this point in the history
  • Loading branch information
anovis committed Apr 6, 2021
1 parent bb5d7f6 commit ebbc7cf
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion tools/c7n_gcp/c7n_gcp/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,8 @@ def __init__(self,
if not credentials:
# Only share the http object when using the default credentials.
self._use_cached_http = True
credentials, _ = google.auth.default()
credentials, _ = google.auth.default(quota_project_id=project_id or
get_default_project())
self._credentials = with_scopes_if_required(credentials, list(CLOUD_SCOPES))
if use_rate_limiter:
self._rate_limiter = RateLimiter(max_calls=quota_max_calls,
Expand Down

0 comments on commit ebbc7cf

Please sign in to comment.