Skip to content

Commit 06ace29

Browse files
committed
Fixes TLS Mode Defaulting
1 parent 4865088 commit 06ace29

File tree

4 files changed

+31
-12
lines changed

4 files changed

+31
-12
lines changed

apis/v1alpha1/gateway_types.go

+11-1
Original file line numberDiff line numberDiff line change
@@ -315,16 +315,25 @@ type GatewayTLSConfig struct {
315315
// implies that the Gateway can't decipher the TLS stream except for
316316
// the ClientHello message of the TLS protocol.
317317
// CertificateRef field is ignored in this mode.
318+
//
319+
// Support: Core
320+
//
321+
// +kubebuilder:default=Terminate
318322
Mode TLSModeType `json:"mode,omitempty"`
319323

320324
// CertificateRef is the reference to Kubernetes object that
321325
// contain a TLS certificate and private key.
322326
// This certificate MUST be used for TLS handshakes for the domain
323327
// this GatewayTLSConfig is associated with.
328+
//
329+
// This field is required when mode is set to "Terminate" and optional
330+
// otherwise.
331+
//
324332
// If an entry in this list omits or specifies the empty
325333
// string for both the group and the resource, the resource defaults to "secrets".
326334
// An implementation may support other resources (for example, resource
327335
// "mycertificates" in group "networking.acme.io").
336+
//
328337
// Support: Core (Kubernetes Secrets)
329338
// Support: Implementation-specific (Other resource types)
330339
//
@@ -338,6 +347,8 @@ type GatewayTLSConfig struct {
338347
// set to 'Allow' as it will be used as the default certificate for the
339348
// listener.
340349
//
350+
// Support: Core
351+
//
341352
// +kubebuilder:default={certificate:Deny}
342353
RouteOverride TLSOverridePolicy `json:"routeOverride,omitempty"`
343354

@@ -357,7 +368,6 @@ type GatewayTLSConfig struct {
357368

358369
// TLSModeType type defines behavior of gateway with TLS protocol.
359370
// +kubebuilder:validation:Enum=Terminate;Passthrough
360-
// +kubebuilder:default=Terminate
361371
type TLSModeType string
362372

363373
const (

config/crd/bases/networking.x-k8s.io_gateways.yaml

+4-3
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs-src/spec.md

+8-4
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/spec/index.html

+8-4
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)