Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Restart network container when container's configure is changed. #2160

Merged
merged 1 commit into from
Nov 5, 2014

Conversation

dchen1107
Copy link
Member

Fix #2099

I could improve this by figuring out if the network related configuration is changed, then decided if restart network container or not. But thought the user expects a blackout time during configuration update anyway.

@dchen1107
Copy link
Member Author

cc @brendandburns

@@ -588,6 +588,14 @@ func (kl *Kubelet) syncPod(pod *api.BoundPod, dockerContainers dockertools.Docke
continue
}
killedContainers[containerID] = empty{}

// Also kill associated network container
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Won't this kill the network container multiple times?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah when there are several containers in a pod, and more than one container with new configurations. If only one has changed, we only kill it once. I could optimize that like what I mentioned in pr description but thought not necessary since we plan to replace network container soon.

@brendandburns
Copy link
Contributor

LGTM, merging.

brendandburns added a commit that referenced this pull request Nov 5, 2014
Restart network container when container's configure is changed.
@brendandburns brendandburns merged commit 0a1493a into kubernetes:master Nov 5, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

PodUpdate doesn't apply any network related changes
3 participants