Move exposed ports and port bindings from Endpoint to Sandbox#810
Move exposed ports and port bindings from Endpoint to Sandbox#810sanimej merged 1 commit intomoby:masterfrom aboch:se
Conversation
|
@aboch I believe this PR is not ready for review yet. Please move the label appropriately when it is ready for review. |
|
@mavenugo @mrjana Please consider this:
|
|
related to moby/moby#18222 |
|
@thaJeztah this is an involved change and we are not comfortable to bring it in for 1.10 release. Can you point me to the issue in docker that is related to this PR ? |
|
@mavenugo Right above, moby/moby#18222 |
|
Ping @aboch for rebase |
|
@tiborvass as suggested above : #810 (comment), we have to see if we can find another simpler solution for moby/moby#18222. @aboch from the look of it, moby/moby#18222 seems to be a random issue and doesn't call for this redesign. Could you please take a look at it again ? |
moby/libnetwork#810 provides the more complete solution for moving the Port-mapping ownership away from endpoint and into Sandbox. But, this PR makes the best use of existing libnetwork design and get a step closer to the gaol. Signed-off-by: Madhu Venugopal <madhu@docker.com>
moby/libnetwork#810 provides the more complete solution for moving the Port-mapping ownership away from endpoint and into Sandbox. But, this PR makes the best use of existing libnetwork design and get a step closer to the gaol. Signed-off-by: Madhu Venugopal <madhu@docker.com>
moby/libnetwork#810 provides the more complete solution for moving the Port-mapping ownership away from endpoint and into Sandbox. But, this PR makes the best use of existing libnetwork design and get a step closer to the gaol. Signed-off-by: Madhu Venugopal <madhu@docker.com>
default_gateway.go
Outdated
| return nil | ||
| } | ||
|
|
||
| func (sb *sandbox) getFirstEndpointWithGateway() *endpoint { |
There was a problem hiding this comment.
Can you pls remove this function ... it is not being used
|
@mavenugo |
|
Thanks for handling the comments. LGTM. |
Signed-off-by: Alessandro Boch <aboch@docker.com>
|
@sanimej |
| if err := sb.updateGateway(gwep); err != nil { | ||
| return err | ||
| } | ||
| if ep == sb.getGatewayEndpoint() { |
There was a problem hiding this comment.
Please retain the check we had to not call updateGateway() if the current ep is not same as gwep. Not having the check will lead to unnecessary calls to updateGateway()
LGTM other than this one comment.
Move exposed ports and port bindings from Endpoint to Sandbox
Signed-off-by: Alessandro Boch aboch@docker.com