mirror of
https://github.com/containous/traefik.git
synced 2025-03-19 18:50:12 +03:00
Add missing headerField in Middleware CRD
This commit is contained in:
parent
cdd24e91b4
commit
d04e2d717c
@ -1238,6 +1238,11 @@ spec:
|
||||
description: ForwardBody defines whether to send the request body
|
||||
to the authentication server.
|
||||
type: boolean
|
||||
headerField:
|
||||
description: |-
|
||||
HeaderField defines a header field to store the authenticated user.
|
||||
More info: https://doc.traefik.io/traefik/v3.3/middlewares/http/forwardauth/#headerfield
|
||||
type: string
|
||||
maxBodySize:
|
||||
description: MaxBodySize defines the maximum body size in bytes
|
||||
allowed to be forwarded to the authentication server.
|
||||
|
@ -496,6 +496,11 @@ spec:
|
||||
description: ForwardBody defines whether to send the request body
|
||||
to the authentication server.
|
||||
type: boolean
|
||||
headerField:
|
||||
description: |-
|
||||
HeaderField defines a header field to store the authenticated user.
|
||||
More info: https://doc.traefik.io/traefik/v3.3/middlewares/http/forwardauth/#headerfield
|
||||
type: string
|
||||
maxBodySize:
|
||||
description: MaxBodySize defines the maximum body size in bytes
|
||||
allowed to be forwarded to the authentication server.
|
||||
|
@ -1238,6 +1238,11 @@ spec:
|
||||
description: ForwardBody defines whether to send the request body
|
||||
to the authentication server.
|
||||
type: boolean
|
||||
headerField:
|
||||
description: |-
|
||||
HeaderField defines a header field to store the authenticated user.
|
||||
More info: https://doc.traefik.io/traefik/v3.3/middlewares/http/forwardauth/#headerfield
|
||||
type: string
|
||||
maxBodySize:
|
||||
description: MaxBodySize defines the maximum body size in bytes
|
||||
allowed to be forwarded to the authentication server.
|
||||
|
@ -252,7 +252,7 @@ type ForwardAuth struct {
|
||||
// AddAuthCookiesToResponse defines the list of cookies to copy from the authentication server response to the response.
|
||||
AddAuthCookiesToResponse []string `json:"addAuthCookiesToResponse,omitempty" toml:"addAuthCookiesToResponse,omitempty" yaml:"addAuthCookiesToResponse,omitempty" export:"true"`
|
||||
// HeaderField defines a header field to store the authenticated user.
|
||||
// More info: https://doc.traefik.io/traefik/v3.0/middlewares/http/forwardauth/#headerfield
|
||||
// More info: https://doc.traefik.io/traefik/v3.3/middlewares/http/forwardauth/#headerfield
|
||||
HeaderField string `json:"headerField,omitempty" toml:"headerField,omitempty" yaml:"headerField,omitempty" export:"true"`
|
||||
// ForwardBody defines whether to send the request body to the authentication server.
|
||||
ForwardBody bool `json:"forwardBody,omitempty" toml:"forwardBody,omitempty" yaml:"forwardBody,omitempty" export:"true"`
|
||||
|
@ -60,6 +60,7 @@ metadata:
|
||||
spec:
|
||||
forwardAuth:
|
||||
address: test.com
|
||||
headerField: X-Header-Field
|
||||
tls:
|
||||
certSecret: tlssecret
|
||||
caSecret: casecret
|
||||
|
@ -789,6 +789,7 @@ func createForwardAuthMiddleware(k8sClient Client, namespace string, auth *traef
|
||||
AuthResponseHeadersRegex: auth.AuthResponseHeadersRegex,
|
||||
AuthRequestHeaders: auth.AuthRequestHeaders,
|
||||
AddAuthCookiesToResponse: auth.AddAuthCookiesToResponse,
|
||||
HeaderField: auth.HeaderField,
|
||||
ForwardBody: auth.ForwardBody,
|
||||
PreserveLocationHeader: auth.PreserveLocationHeader,
|
||||
}
|
||||
|
@ -3961,6 +3961,7 @@ func TestLoadIngressRoutes(t *testing.T) {
|
||||
ForwardAuth: &dynamic.ForwardAuth{
|
||||
Address: "test.com",
|
||||
MaxBodySize: pointer(int64(-1)),
|
||||
HeaderField: "X-Header-Field",
|
||||
TLS: &dynamic.ClientTLS{
|
||||
CA: "-----BEGIN CERTIFICATE-----\n-----END CERTIFICATE-----",
|
||||
Cert: "-----BEGIN CERTIFICATE-----\n-----END CERTIFICATE-----",
|
||||
|
@ -161,6 +161,9 @@ type ForwardAuth struct {
|
||||
TLS *ClientTLS `json:"tls,omitempty"`
|
||||
// AddAuthCookiesToResponse defines the list of cookies to copy from the authentication server response to the response.
|
||||
AddAuthCookiesToResponse []string `json:"addAuthCookiesToResponse,omitempty"`
|
||||
// HeaderField defines a header field to store the authenticated user.
|
||||
// More info: https://doc.traefik.io/traefik/v3.3/middlewares/http/forwardauth/#headerfield
|
||||
HeaderField string `json:"headerField,omitempty"`
|
||||
// ForwardBody defines whether to send the request body to the authentication server.
|
||||
ForwardBody bool `json:"forwardBody,omitempty"`
|
||||
// MaxBodySize defines the maximum body size in bytes allowed to be forwarded to the authentication server.
|
||||
|
Loading…
x
Reference in New Issue
Block a user