Skip to content

Commit

Permalink
update Gateway API to v0.4.1
Browse files Browse the repository at this point in the history
Signed-off-by: Steve Kriss <krisss@vmware.com>
  • Loading branch information
skriss committed Jan 12, 2022
1 parent e1f295b commit c289aba
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 3 deletions.
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,6 @@ require (
k8s.io/utils v0.0.0-20210930125809-cb0fa318a74b
sigs.k8s.io/controller-runtime v0.11.0
sigs.k8s.io/controller-tools v0.6.2
sigs.k8s.io/gateway-api v0.4.0
sigs.k8s.io/gateway-api v0.4.1
sigs.k8s.io/kustomize/kyaml v0.10.17
)
2 changes: 2 additions & 0 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -1746,6 +1746,8 @@ sigs.k8s.io/controller-tools v0.6.2/go.mod h1:oaeGpjXn6+ZSEIQkUe/+3I40PNiDYp9aea
sigs.k8s.io/gateway-api v0.3.0/go.mod h1:Wb8bx7QhGVZxOSEU3i9vw/JqTB5Nlai9MLMYVZeDmRQ=
sigs.k8s.io/gateway-api v0.4.0 h1:07IJkTt21NetZTHtPKJk2I4XIgDN4BAlTIq1wK7V11o=
sigs.k8s.io/gateway-api v0.4.0/go.mod h1:r3eiNP+0el+NTLwaTfOrCNXy8TukC+dIM3ggc+fbNWk=
sigs.k8s.io/gateway-api v0.4.1 h1:Tof9/PNSZXyfDuTTe1XFvaTlvBRE6bKq1kmV6jj6rQE=
sigs.k8s.io/gateway-api v0.4.1/go.mod h1:r3eiNP+0el+NTLwaTfOrCNXy8TukC+dIM3ggc+fbNWk=
sigs.k8s.io/json v0.0.0-20211020170558-c049b76a60c6 h1:fD1pz4yfdADVNfFmcP2aBEtudwUQ1AlLnRBALr33v3s=
sigs.k8s.io/json v0.0.0-20211020170558-c049b76a60c6/go.mod h1:p4QtZmO4uMYipTQNzagwnNoseA6OxSUutVw05NhYDRs=
sigs.k8s.io/kustomize/api v0.8.5/go.mod h1:M377apnKT5ZHJS++6H4rQoCHmWtt6qTpp3mbe7p6OLY=
Expand Down
4 changes: 2 additions & 2 deletions internal/dag/builder_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -2938,7 +2938,7 @@ func TestDAGInsertGatewayAPI(t *testing.T) {
Type: gatewayapi_v1alpha2.HTTPRouteFilterRequestRedirect,
RequestRedirect: &gatewayapi_v1alpha2.HTTPRequestRedirectFilter{
Scheme: pointer.String("https"),
Hostname: gatewayapi.ListenerHostname("envoyproxy.io"),
Hostname: gatewayapi.PreciseHostname("envoyproxy.io"),
Port: gatewayapi.PortNumPtr(443),
StatusCode: pointer.Int(301),
},
Expand Down Expand Up @@ -2991,7 +2991,7 @@ func TestDAGInsertGatewayAPI(t *testing.T) {
Type: gatewayapi_v1alpha2.HTTPRouteFilterRequestRedirect,
RequestRedirect: &gatewayapi_v1alpha2.HTTPRequestRedirectFilter{
Scheme: pointer.String("https"),
Hostname: gatewayapi.ListenerHostname("envoyproxy.io"),
Hostname: gatewayapi.PreciseHostname("envoyproxy.io"),
Port: gatewayapi.PortNumPtr(443),
StatusCode: pointer.Int(301),
},
Expand Down
5 changes: 5 additions & 0 deletions internal/gatewayapi/helpers.go
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,11 @@ func ListenerHostname(host string) *gatewayapi_v1alpha2.Hostname {
return &h
}

func PreciseHostname(host string) *gatewayapi_v1alpha2.PreciseHostname {
h := gatewayapi_v1alpha2.PreciseHostname(host)
return &h
}

func CertificateRef(name, namespace string) *gatewayapi_v1alpha2.SecretObjectReference {
ref := &gatewayapi_v1alpha2.SecretObjectReference{
Group: GroupPtr(""),
Expand Down

0 comments on commit c289aba

Please sign in to comment.