• Kubernetes Submit Queue's avatar
    Merge pull request #49140 from rickypai/rpai/hostnetwork_etc_hosts · b161831b
    Kubernetes Submit Queue authored
    Automatic merge from submit-queue (batch tested with PRs 50094, 48966, 49478, 50593, 49140)
    
    Kubelet manage hosts file for HostNetwork Pods instead of Docker
    
    **What this PR does / why we need it**: Currently, Docker manages the hosts file for containers inside Pods using hostNetwork. It creates discrepancy between how we treat hostNetwork and non-hostNetwork Pods. Kubelet should manage the file regardless of the network setup.
    
    **Which issue this PR fixes**: fixes #48397 more context in https://github.com/kubernetes/kubernetes/issues/43632#issuecomment-304376441
    
    **Special notes for your reviewer**: Because the new logic relies on reading the node filesystem, I'm not sure how to write a proper unit test. I was thinking about using a node e2e test to cover the case, but suggestions are greatly welcomed.
    
    **Release note**:
    ```release-note
    Kubelet now manages `/etc/hosts` file for both hostNetwork Pods and non-hostNetwork Pods.
    ```
    
    /kind feature
    /sig node
    
    @yujuhong @hongchaodeng @thockin
    @kubernetes/sig-network-feature-requests @kubernetes/sig-node-feature-requests
    b161831b
Name
Last commit
Last update
.github Loading commit data...
Godeps Loading commit data...
api Loading commit data...
build Loading commit data...
cluster Loading commit data...
cmd Loading commit data...
docs Loading commit data...
examples Loading commit data...
federation Loading commit data...
hack Loading commit data...
logo Loading commit data...
pkg Loading commit data...
plugin Loading commit data...
staging Loading commit data...
test Loading commit data...
third_party Loading commit data...
translations Loading commit data...
vendor Loading commit data...
.bazelrc Loading commit data...
.generated_files Loading commit data...
.gitattributes Loading commit data...
.gitignore Loading commit data...
.kazelcfg.json Loading commit data...
BUILD.bazel Loading commit data...
CHANGELOG.md Loading commit data...
CONTRIBUTING.md Loading commit data...
LICENSE Loading commit data...
Makefile Loading commit data...
Makefile.generated_files Loading commit data...
OWNERS Loading commit data...
OWNERS_ALIASES Loading commit data...
README.md Loading commit data...
SUPPORT.md Loading commit data...
Vagrantfile Loading commit data...
WORKSPACE Loading commit data...
code-of-conduct.md Loading commit data...
labels.yaml Loading commit data...