1
0
Fork 0

Add GrpcWeb middleware

Co-authored-by: Kevin Pollet <pollet.kevin@gmail.com>
This commit is contained in:
Julien Salleyron 2022-10-27 17:34:06 +02:00 committed by GitHub
parent 7a6bfd3336
commit bd3eaf4f5e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
19 changed files with 251 additions and 2 deletions

View file

@ -279,6 +279,7 @@ func (p *Provider) loadConfigurationFromCRD(ctx context.Context, client Client)
PassTLSClientCert: middleware.Spec.PassTLSClientCert,
Retry: retry,
ContentType: middleware.Spec.ContentType,
GrpcWeb: middleware.Spec.GrpcWeb,
Plugin: plugin,
}
}

View file

@ -48,6 +48,7 @@ type MiddlewareSpec struct {
PassTLSClientCert *dynamic.PassTLSClientCert `json:"passTLSClientCert,omitempty"`
Retry *Retry `json:"retry,omitempty"`
ContentType *dynamic.ContentType `json:"contentType,omitempty"`
GrpcWeb *dynamic.GrpcWeb `json:"grpcWeb,omitempty"`
// Plugin defines the middleware plugin configuration.
// More info: https://doc.traefik.io/traefik/plugins/
Plugin map[string]apiextensionv1.JSON `json:"plugin,omitempty"`

View file

@ -769,6 +769,11 @@ func (in *MiddlewareSpec) DeepCopyInto(out *MiddlewareSpec) {
*out = new(dynamic.ContentType)
**out = **in
}
if in.GrpcWeb != nil {
in, out := &in.GrpcWeb, &out.GrpcWeb
*out = new(dynamic.GrpcWeb)
(*in).DeepCopyInto(*out)
}
if in.Plugin != nil {
in, out := &in.Plugin, &out.Plugin
*out = make(map[string]v1.JSON, len(*in))