Skip to content

Unified SecretStore for Environment and Keyring resolution#24

Open
cdvelop wants to merge 1 commit into
mainfrom
feat-unified-secret-store-10880722830233109775
Open

Unified SecretStore for Environment and Keyring resolution#24
cdvelop wants to merge 1 commit into
mainfrom
feat-unified-secret-store-10880722830233109775

Conversation

@cdvelop

@cdvelop cdvelop commented Jun 5, 2026

Copy link
Copy Markdown
Collaborator

This change introduces a unified SecretStore component that centralizes credential management. It resolves secrets by checking environment variables first and falling back to the system keyring only if necessary. This allows devflow tools (gorelease, gopush, codejob) to run in CI/CD and headless environments without user interaction, while maintaining the current interactive experience for local development.

Key changes:

  • New secret_store.go with SecretStore implementation and thread-safe lazy keyring initialization.
  • Migration of github_auth.go and codejob_auth.go to use the new store.
  • Updated docs/GORELEASE.md, docs/CODEJOB.md, and docs/github/diagrams/GITHUB_AUTH_FLOW.md with CI/CD usage instructions and updated flow diagrams.
  • New tests in test/secret_store_test.go verifying the precedence and lazy initialization logic.

PR created automatically by Jules for task 10880722830233109775 started by @cdvelop

- Created `SecretStore` to manage credentials with environment -> keyring precedence.
- Migrated `GitHubAuth` and `JulesAuth` to use `SecretStore`.
- Added headless/CI support by prioritizing `GH_TOKEN`, `GITHUB_TOKEN`, and `JULES_API_KEY`.
- Added `IsInteractive()` helper to handle non-TTY environments.
- Updated documentation and diagrams to reflect the new auth flow.
- Added integration tests for `SecretStore`.

Co-authored-by: cdvelop <44058491+cdvelop@users.noreply.github.com>
@google-labs-jules

Copy link
Copy Markdown
Contributor

👋 Jules, reporting for duty! I'm here to lend a hand with this pull request.

When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down.

I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job!

For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with @jules. You can find this option in the Pull Request section of your global Jules UI settings. You can always switch back!

New to Jules? Learn more at jules.google/docs.


For security, I will only act on instructions from the user who triggered this task.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant