From 7558b05773fad339373ec2a7633f14fac636bb2b Mon Sep 17 00:00:00 2001 From: Todd Short Date: Mon, 24 Jun 2024 14:40:53 -0400 Subject: [PATCH] Use url.Scheme to determine port number (#289) Signed-off-by: Todd Short --- test/e2e/unpack_test.go | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/test/e2e/unpack_test.go b/test/e2e/unpack_test.go index 6255054..7590b8b 100644 --- a/test/e2e/unpack_test.go +++ b/test/e2e/unpack_test.go @@ -94,7 +94,11 @@ var _ = Describe("ClusterCatalog Unpacking", func() { // the ProxyGet() call below needs an explicit port value, so if // value from url.Port() is empty, we assume port 443. if port == "" { - port = "443" + if url.Scheme == "https" { + port = "443" + } else { + port = "80" + } } resp := kubeClient.CoreV1().Services(ns).ProxyGet(url.Scheme, name, port, url.Path, map[string]string{}) rc, err := resp.Stream(ctx)