From d382f299a1e050c32b5daad214cc4db1ac71c833 Mon Sep 17 00:00:00 2001 From: Antonio Ojea Date: Tue, 15 Sep 2020 17:07:06 +0200 Subject: [PATCH] fix e2e service test container listening port the e2e test container used for the "Networking Granular Checks: Services" tests only needs to listen in one port to perform do network checks. This port is unrelated to the other ports used in the test, so we may use a different number to avoid possible conflicts. --- test/e2e/framework/network/utils.go | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/test/e2e/framework/network/utils.go b/test/e2e/framework/network/utils.go index d0d05369ded..2f23633752c 100644 --- a/test/e2e/framework/network/utils.go +++ b/test/e2e/framework/network/utils.go @@ -53,8 +53,9 @@ const ( // EndpointUDPPort is an endpoint UDP port for testing. EndpointUDPPort = 8081 // EndpointSCTPPort is an endpoint SCTP port for testing. - EndpointSCTPPort = 8082 - testContainerHTTPPort = 8080 + EndpointSCTPPort = 8082 + // testContainerHTTPPort is the test container http port. + testContainerHTTPPort = 9080 // ClusterHTTPPort is a cluster HTTP port for testing. ClusterHTTPPort = 80 // ClusterUDPPort is a cluster UDP port for testing. @@ -573,8 +574,7 @@ func (config *NetworkingTestConfig) createTestPodSpec() *v1.Pod { ImagePullPolicy: v1.PullIfNotPresent, Args: []string{ "netexec", - fmt.Sprintf("--http-port=%d", EndpointHTTPPort), - fmt.Sprintf("--udp-port=%d", EndpointUDPPort), + fmt.Sprintf("--http-port=%d", testContainerHTTPPort), }, Ports: []v1.ContainerPort{ { @@ -586,10 +586,6 @@ func (config *NetworkingTestConfig) createTestPodSpec() *v1.Pod { }, }, } - // we want sctp to be optional as it will load the sctp kernel module - if config.SCTPEnabled { - pod.Spec.Containers[0].Args = append(pod.Spec.Containers[0].Args, fmt.Sprintf("--sctp-port=%d", EndpointSCTPPort)) - } return pod }