feat(key): add correctly scoped environment variables for setting GCloud key#2
Merged
skevetter merged 1 commit intoskevetter:mainfrom Jan 9, 2026
Conversation
…oud key Currently, there are two ways to communicate GCloud key to the provider: 1. Set `GOOGLE_APPLICATION_CREDENTIALS` environment variable to point to the file with the JSON key. This is too generic: it is likely that the key for DevPod belongs to a dedicated service account, whereas other GCloud operations that the developer performs from the same directory use different keys (e.g., Cloud Run with a different service account etc.). We need an ability to communicate the key in a DevPod-specific way. 2. Set `GCLOUD_JSON_AUTH` environment variable to the actual JSON key. Although this variable *is* DevPod-specific, this fact is not obvious from its name, which is not scoped. We need an ability to communicate the key in a *clearly* DevPod-specific way :) This pull request adds handling for two new environment variables, with names clearly scoped for DevPod: 1. `DEVPOD_PROVIDER_GCLOUD_KEY_FILE` is a correctly scoped synonym for the `GOOGLE_APPLICATION_CREDENTIALS` (which is set from it if it is set :)); it points to the file with the JSON key. 2. `DEVPOD_PROVIDER_GCLOUD_KEY` is a correctly scoped synonym for the `GCLOUD_JSON_AUTH`; it contains the actual JSON key.
967b79a to
6b4f7e0
Compare
Author
|
@skevetter please take a look ;) |
skevetter
approved these changes
Jan 9, 2026
Author
|
Thank you! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Currently, there are two ways to communicate GCloud key to the provider:
Set
GOOGLE_APPLICATION_CREDENTIALSenvironment variable to point to the file with the JSON key. This is too generic: it is likely that the key for DevPod belongs to a dedicated service account, whereas other GCloud operations that the developer performs from the same directory use different keys (e.g., Cloud Run with a different service account etc.). We need an ability to communicate the key in a DevPod-specific way.Set
GCLOUD_JSON_AUTHenvironment variable to the actual JSON key. Although this variable is DevPod-specific, this fact is not obvious from its name, which is not scoped. We need an ability to communicate the key in a clearly DevPod-specific way :)This pull request adds handling for two new environment variables, with names clearly scoped for DevPod:
DEVPOD_PROVIDER_GCLOUD_KEY_FILEis a correctly scoped synonym for theGOOGLE_APPLICATION_CREDENTIALS(which is set from it if it is set :)); it points to the file with the JSON key.DEVPOD_PROVIDER_GCLOUD_KEYis a correctly scoped synonym for theGCLOUD_JSON_AUTH; it contains the actual JSON key.