File tree Expand file tree Collapse file tree 2 files changed +21
-3
lines changed
packages/clients/src/api/lb/v1 Expand file tree Collapse file tree 2 files changed +21
-3
lines changed Original file line number Diff line number Diff line change @@ -463,7 +463,7 @@ const unmarshalRouteMatch = (data: unknown) => {
463
463
)
464
464
}
465
465
466
- return { sni : data . sni } as RouteMatch
466
+ return { hostHeader : data . host_header , sni : data . sni } as RouteMatch
467
467
}
468
468
469
469
export const unmarshalAcl = ( data : unknown ) => {
@@ -903,7 +903,16 @@ const marshalRouteMatch = (
903
903
request : RouteMatch ,
904
904
defaults : DefaultValues ,
905
905
) : Record < string , unknown > => ( {
906
- sni : request . sni ,
906
+ ...resolveOneOf ( [
907
+ {
908
+ param : 'sni' ,
909
+ value : request . sni ,
910
+ } ,
911
+ {
912
+ param : 'host_header' ,
913
+ value : request . hostHeader ,
914
+ } ,
915
+ ] ) ,
907
916
} )
908
917
909
918
const marshalSubscriberEmailConfig = (
Original file line number Diff line number Diff line change @@ -728,9 +728,18 @@ export interface Route {
728
728
export interface RouteMatch {
729
729
/**
730
730
* Server Name Indication TLS extension (SNI) field from an incoming
731
- * connection made via an SSL/TLS transport layer
731
+ * connection made via an SSL/TLS transport layer.
732
+ *
733
+ * One-of ('matchType'): at most one of 'sni', 'hostHeader' could be set.
732
734
*/
733
735
sni ?: string
736
+ /**
737
+ * The Host request header specifies the host of the server to which the
738
+ * request is being sent.
739
+ *
740
+ * One-of ('matchType'): at most one of 'sni', 'hostHeader' could be set.
741
+ */
742
+ hostHeader ?: string
734
743
}
735
744
736
745
/** Set acls response */
You can’t perform that action at this time.
0 commit comments