Skip to content

Commit

Permalink
Add hostname override to AI upstream customHost setting (#10640)
Browse files Browse the repository at this point in the history
Co-authored-by: changelog-bot <changelog-bot>
  • Loading branch information
andy-fong authored Feb 24, 2025
1 parent c03f3c5 commit 3a0c8a5
Show file tree
Hide file tree
Showing 9 changed files with 531 additions and 424 deletions.
6 changes: 6 additions & 0 deletions changelog/v1.19.0-beta12/ai-upstream-custom-hostname.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
changelog:
- type: NEW_FEATURE
issueLink: https://github.com/solo-io/solo-projects/issues/7831
resolvesIssue: false
description: >
Added optional `hostname` to the AI Upstream CustomHost setting to override SNI and host header value

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

18 changes: 18 additions & 0 deletions install/helm/gloo/crds/gloo.solo.io_v1_Upstream.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,9 @@ spec:
properties:
host:
type: string
hostname:
nullable: true
type: string
port:
maximum: 4294967295
minimum: 0
Expand Down Expand Up @@ -121,6 +124,9 @@ spec:
properties:
host:
type: string
hostname:
nullable: true
type: string
port:
maximum: 4294967295
minimum: 0
Expand Down Expand Up @@ -157,6 +163,9 @@ spec:
properties:
host:
type: string
hostname:
nullable: true
type: string
port:
maximum: 4294967295
minimum: 0
Expand Down Expand Up @@ -231,6 +240,9 @@ spec:
properties:
host:
type: string
hostname:
nullable: true
type: string
port:
maximum: 4294967295
minimum: 0
Expand Down Expand Up @@ -259,6 +271,9 @@ spec:
properties:
host:
type: string
hostname:
nullable: true
type: string
port:
maximum: 4294967295
minimum: 0
Expand Down Expand Up @@ -322,6 +337,9 @@ spec:
properties:
host:
type: string
hostname:
nullable: true
type: string
port:
maximum: 4294967295
minimum: 0
Expand Down
6 changes: 5 additions & 1 deletion projects/gloo/api/v1/enterprise/options/ai/ai.proto
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ option go_package = "github.com/solo-io/gloo/projects/gloo/pkg/api/v1/enterprise

import "github.com/solo-io/solo-kit/api/v1/ref.proto";
import "google/protobuf/struct.proto";
import "google/protobuf/wrappers.proto";
import "extproto/ext.proto";
option (extproto.equal_all) = true;
option (extproto.hash_all) = true;
Expand Down Expand Up @@ -60,10 +61,13 @@ message UpstreamSpec {
// Send requests to a custom host and port, such as to proxy the request,
// or to use a different backend that is API-compliant with the upstream version.
message CustomHost {
// Custom host to send the traffic requests to.
// Custom host or IP address to send the traffic requests to.
string host = 1;
// Custom port to send the traffic requests to.
uint32 port = 2;
// Optional: hostname used to set the SNI (if is secure connection) and the host request header.
// If hostname is not set, host will be used instead
google.protobuf.StringValue hostname = 3;
}

// Settings for the [OpenAI](https://platform.openai.com/docs/overview) LLM provider.
Expand Down
8 changes: 8 additions & 0 deletions projects/gloo/pkg/api/v1/enterprise/options/ai/ai.pb.clone.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 10 additions & 0 deletions projects/gloo/pkg/api/v1/enterprise/options/ai/ai.pb.equal.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 3a0c8a5

Please sign in to comment.