fix(supervisor): opt-out for persisting provider creds in service file#1787
Open
eric-jones wants to merge 1 commit intogastownhall:mainfrom
Open
fix(supervisor): opt-out for persisting provider creds in service file#1787eric-jones wants to merge 1 commit intogastownhall:mainfrom
eric-jones wants to merge 1 commit intogastownhall:mainfrom
Conversation
Adds GC_SUPERVISOR_OMIT_PROVIDER_CREDS. When set to "1" at the time the supervisor service file is generated, provider-credential env vars (ANTHROPIC_*, GEMINI_*, GOOGLE_*, OPENAI_*) are excluded from the generated launchd plist or systemd unit. Default behavior is unchanged. Background: provider creds are persisted in plaintext (mode 0600) into the service file by design (gastownhall#1198) so launchd/systemd-spawned supervisors can deliver creds to agent sessions. The opt-out gives users who'd prefer to avoid the on-disk plaintext (Time Machine backups, crash dumps, regression surface) a way to disable persistence and deliver creds via another mechanism. Refs gastownhall#1786.
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
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.
Summary
Adds an opt-out env var,
GC_SUPERVISOR_OMIT_PROVIDER_CREDS. When set to"1"at the time the supervisor service file is generated, provider-credential env
vars (
ANTHROPIC_*,GEMINI_*,GOOGLE_*,OPENAI_*) are excluded from thegenerated launchd plist / systemd unit. Default behavior is unchanged.
Background — provider creds are persisted in plaintext (mode 0600) into the
service file by design (#1198) so launchd/systemd-spawned supervisors can
deliver creds to agent sessions. The opt-out gives users who'd prefer to avoid
the on-disk plaintext (Time Machine backup posture, crash dumps, regression
surface) a way to disable persistence and deliver creds to the supervisor by
another mechanism (e.g. a wrapper around
gc supervisor run).This is the smallest concrete proposal in #1786; happy to take a different
direction if preferred (e.g. credentials-file loading at supervisor start,
Keychain).
Testing
make check— passes locally except for documented pre-existingfailures on
origin/main(none related to this change):TestBuiltinDoltDoctorBoundsVersionProbe— fixed by fix(macos): unblock pre-commit hook on macOS dev machines #1729 (open)TestBuiltinDoltDoctorReportsTimedOutVersionProbe— fixed by fix(macos): unblock pre-commit hook on macOS dev machines #1729 (open)TestExecCommandRunnerTimeoutKillsChildProcess— fixed by fix(macos): unblock pre-commit hook on macOS dev machines #1729 (open)make check-docs— no docs touchedmake test-integration— not rungo test ./cmd/gc -run 'TestBuildSupervisorServiceData' -count=1— green,including the new
TestBuildSupervisorServiceDataOmitsProviderEnvWhenOptedOutChecklist
inline at the const declaration
Need help on this PR? Tag
@codesmithwith what you need.