Skip to content

fix: persist hostname-override flag to context#630

Open
ivanauth wants to merge 1 commit intoauthzed:mainfrom
ivanauth:fix/issue-593-persist-hostname-override
Open

fix: persist hostname-override flag to context#630
ivanauth wants to merge 1 commit intoauthzed:mainfrom
ivanauth:fix/issue-593-persist-hostname-override

Conversation

@ivanauth
Copy link
Contributor

Fixes #593

Persists --hostname-override to zed context storage, matching the existing pattern for --insecure and --no-verify-ca. CLI flag still overrides stored value when explicitly set.

The --hostname-override flag was not persisted when setting a context,
requiring users to pass it on every command. This adds hostname-override
to the Token struct and saves it alongside other TLS-related flags like
--insecure and --no-verify-ca during `zed context set`. Subcommands now
read hostname-override from the stored context, with CLI flags still
taking precedence when explicitly provided.

Signed-off-by: ivanauth <ivan@authzed.com>
@codecov-commenter
Copy link

Codecov Report

❌ Patch coverage is 53.57143% with 13 lines in your changes missing coverage. Please review.
✅ Project coverage is 41.70%. Comparing base (56e9ecd) to head (3681aa7).

Files with missing lines Patch % Lines
internal/cmd/context.go 0.00% 8 Missing ⚠️
internal/client/client.go 58.33% 3 Missing and 2 partials ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #630      +/-   ##
==========================================
- Coverage   41.72%   41.70%   -0.02%     
==========================================
  Files          38       38              
  Lines        6131     6138       +7     
==========================================
+ Hits         2558     2560       +2     
- Misses       3317     3321       +4     
- Partials      256      257       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

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.

[bug] Add hostname-override flag to root command to support overriding SNI hostname

2 participants