Sets HostNetwork to False for tests which do not require it#69525
Sets HostNetwork to False for tests which do not require it#69525claudiubelu wants to merge 1 commit intokubernetes:masterfrom
Conversation
|
SGTM /ok-to-test |
|
/test pull-kubernetes-e2e-gce |
|
/milestone 1.13 |
|
@PatrickLang: You must be a member of the kubernetes/kubernetes-milestone-maintainers github team to set the milestone. DetailsIn response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
|
/milestone 1.13 |
|
@feiskyer: The provided milestone is not valid for this repository. Milestones in this repository: [ Use DetailsIn response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
|
/milestone v1.13 |
test/e2e/framework/util.go
Outdated
There was a problem hiding this comment.
Will this function work if not in hostNetwork?
It seems to me that it is relying on hitting the host at a given port via localhost, which won't resolve the same when run in hostNetwork vs pod networked.
There was a problem hiding this comment.
Apparently so. The only place this is used in, is in the test should preserve source pod IP for traffic thru service cluster IP, which is even marked as passed in the pull-kubernetes-e2e-kops-aws and the pull-kubernetes-e2e-gce jobs.
There was a problem hiding this comment.
Something is fishy about that. This is exec'ing into a pod and curling a localhost URL of a sleep pod.
kubernetes/test/e2e/framework/util.go
Line 3431 in 8616687
kubernetes/test/e2e/network/networking.go
Line 87 in 7f23a74
kubernetes/cmd/kube-proxy/app/server.go
Line 507 in ef19542
There was a problem hiding this comment.
And why isn't this using the same exec pod spec / image?
There was a problem hiding this comment.
I can't speak to history of this implementation, but there's been a lot of evolution in network tests, so it would not surprise me that this didn't get updated at some point to a consistent pod spec.
This function can not possibly work without hostNetwork.
The good news is that the calling test doesn't abort in this case, but just logs "the rest of this might fail". I guess you are NOT failing so this is a lot of noise about nothing.
But for this PR: you can't parameterize this function - it doesn't make sense.
Better fix: fix the calling test to skip this path entirely on windows, with a big comment about why
f745331 to
b4293a3
Compare
|
/lgtm Thanks @BCLAU |
|
/approve |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: bclau, timothysc The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
|
@thockin @caseydavenport @bowei: This needs a thorough review by someone from SIG Network. Which tests are intending to test service reachability from a pod perspective, and which ones, if any, are deliberately testing host reachability? |
|
I removed lgtm and approval until we hear from SIG Network. |
|
/assign @thockin |
thockin
left a comment
There was a problem hiding this comment.
I think a lot of these cannot be changed as you propose, but I also think a lot of the kube-proxy details should not be conformance tests.
test/e2e/framework/util.go
Outdated
There was a problem hiding this comment.
I can't speak to history of this implementation, but there's been a lot of evolution in network tests, so it would not surprise me that this didn't get updated at some point to a consistent pod spec.
This function can not possibly work without hostNetwork.
The good news is that the calling test doesn't abort in this case, but just logs "the rest of this might fail". I guess you are NOT failing so this is a lot of noise about nothing.
But for this PR: you can't parameterize this function - it doesn't make sense.
Better fix: fix the calling test to skip this path entirely on windows, with a big comment about why
|
|
||
| It("should function for node-Service: http", func() { | ||
| config := framework.NewNetworkingTestConfig(f) | ||
| config := framework.NewNetworkingTestConfig(f, false) |
There was a problem hiding this comment.
I don't see how this can pass - it is specifically about testing from the node...
|
|
||
| It("should function for node-Service: udp", func() { | ||
| config := framework.NewNetworkingTestConfig(f) | ||
| config := framework.NewNetworkingTestConfig(f, false) |
| // Slow because we confirm that the nodePort doesn't serve traffic, which requires a period of polling. | ||
| It("should update nodePort: http [Slow]", func() { | ||
| config := framework.NewNetworkingTestConfig(f) | ||
| config := framework.NewNetworkingTestConfig(f, false) |
There was a problem hiding this comment.
This too - DialFromNode should not work without HostNetwork
| Expect(err).NotTo(HaveOccurred()) | ||
|
|
||
| hostExec := framework.LaunchHostExecPod(f.ClientSet, f.Namespace.Name, "hostexec") | ||
| hostExec := framework.LaunchHostExecPod(f.ClientSet, f.Namespace.Name, "hostexec", false) |
There was a problem hiding this comment.
How would this work without hostNet? It expects ss to be able to run and see kube-proxy
|
This needs to move to v1.14 so it can be updated once we have a decision on Windows conformance profiles and how they will be implemented. |
|
ack @PatrickLang moving to 1.14 /milestone v1.14 |
|
Issues go stale after 90d of inactivity. If this issue is safe to close now please do so with Send feedback to sig-testing, kubernetes/test-infra and/or fejta. |
|
@PatrickLang any chance this is merged in the following 2 weeks? |
|
Closed in favor of: #71468 |
|
For some reason, I cannot reopen this PR, but i've sent another PR for it. #78731 Additional information: Running the tests affected by this PR on Linux nodes on different environments, yielded the following results:
|
What this PR does / why we need it:
Some tests are setting HostNetwork=true, even if it is not required
for them to pass.
This patch will set the HostNetwork to false for those tests, allowing
them to be run on Windows nodes as well.
/sig testing
Which issue(s) this PR fixes (optional, in
fixes #<issue number>(, fixes #<issue_number>, ...)format, will close the issue(s) when PR gets merged):Fixes #69559
Special notes for your reviewer:
Release note: