-
Notifications
You must be signed in to change notification settings - Fork 431
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
✨ Add webhook-cert-dir flag #4151
Conversation
Codecov ReportAll modified lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #4151 +/- ##
==========================================
+ Coverage 57.83% 57.87% +0.03%
==========================================
Files 187 187
Lines 19197 19212 +15
==========================================
+ Hits 11103 11118 +15
Misses 7466 7466
Partials 628 628 ☔ View full report in Codecov by Sentry. |
main.go
Outdated
@@ -224,6 +225,9 @@ func InitFlags(fs *pflag.FlagSet) { | |||
"Webhook Server port, disabled by default. When enabled, the manager will only work as webhook server, no reconcilers are installed.", | |||
) | |||
|
|||
fs.StringVar(&webhookCertDir, "webhook-cert-dir", "", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In CAPI, this flag has a default value. Does CAPZ need to do the same here?
"only used when webhook-port is specified."
Does this mean the value is ignored unless --webhook-port
was overridden? The code just passes both values through regardless.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I copied the flag, but dropped the default because I noticed it was already set in the Deployment yaml; can add it back if we prefer.
The comment is a bit confusing, I agree.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it was already set in the Deployment yaml;
Ah, I missed that. Thanks for updating, I think this is more clear.
Adds the --webhook-cert-dir flag to customize where the certificates are stored, and passes it to the controller-runtime webhook handler. Signed-off-by: Vince Prignano <[email protected]>
d6bbad6
to
b48d686
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
LGTM label has been added. Git tree hash: 6b7833142ef9437947c8d93c849f40aed9f1c95d
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
/approve
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: CecileRobertMichon The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
What type of PR is this?
/kind feature
What this PR does / why we need it:
Adds the --webhook-cert-dir flag to customize where the certificates are stored, and passes it to the controller-runtime webhook handler.
Which issue(s) this PR fixes (optional, in
fixes #<issue number>(, fixes #<issue_number>, ...)
format, will close the issue(s) when PR gets merged):Fixes #
Special notes for your reviewer:
TODOs:
Release note: