Skip to content

Commit 584147d

Browse files
committed
Document that pod template spec should be used instead of flags
For configuring ACME HTTP-01 solver pod Signed-off-by: irbekrm <[email protected]>
1 parent 58b226e commit 584147d

File tree

2 files changed

+11
-0
lines changed

2 files changed

+11
-0
lines changed

cmd/controller/app/options/options.go

+5
Original file line numberDiff line numberDiff line change
@@ -290,6 +290,11 @@ func (s *ControllerOptions) AddFlags(fs *pflag.FlagSet) {
290290
"'foo'.\nAll controllers: %s",
291291
strings.Join(allControllers, ", ")))
292292

293+
// HTTP-01 solver pod configuration via flags is a now deprecated
294+
// mechanism- please use pod template instead when adding any new
295+
// configuration options
296+
// https://github.com/cert-manager/cert-manager/blob/f1d7c432763100c3fb6eb6a1654d29060b479b3c/pkg/apis/acme/v1/types_issuer.go#L270
297+
// These flags however will not be deprecated for backwards compatibility purposes.
293298
fs.StringVar(&s.ACMEHTTP01SolverImage, "acme-http01-solver-image", defaultACMEHTTP01SolverImage, ""+
294299
"The docker image to use to solve ACME HTTP01 challenges. You most likely will not "+
295300
"need to change this parameter unless you are testing a new feature or developing cert-manager.")

pkg/issuer/acme/http/pod.go

+6
Original file line numberDiff line numberDiff line change
@@ -155,6 +155,12 @@ func (s *Solver) buildPod(ch *cmacme.Challenge) *corev1.Pod {
155155
return pod
156156
}
157157

158+
// Note: this function builds pod spec using defaults and any configuration
159+
// options passed via flags to cert-manager controller.
160+
// Solver pod configuration via flags is a now deprecated
161+
// mechanism- please use pod template instead when adding any new
162+
// configuration options
163+
// https://github.com/cert-manager/cert-manager/blob/f1d7c432763100c3fb6eb6a1654d29060b479b3c/pkg/apis/acme/v1/types_issuer.go#L270
158164
func (s *Solver) buildDefaultPod(ch *cmacme.Challenge) *corev1.Pod {
159165
podLabels := podLabels(ch)
160166

0 commit comments

Comments
 (0)