Skip to content

Conversation

rycus86
Copy link
Contributor

@rycus86 rycus86 commented Jan 12, 2018

Hi,

A user has reported to me that my change (b2d08e6#diff-627477fe9d783a0f4c5f8627948efbb1) has broken service network create/update on Docker version 1.12.

I'm now exploring Docker versions between 1.12.6 and 17.09.0. When I ported my code from 17.09.0 to 1.12.6 for compatibility test, I found probably a python SDK issue made my swarm service unexpectedly created. The service didn't attach to the specified network but to the default one 'ingress'.

Looked at the code, probably the git commit as below introduced this issue. In this commit on source file docker/models/services.py, the argument "networks" removed from the array of "CREATE_SERVICE_KWARGS". I manually added it then the issue gone.

BTW, the APIClient() call "create_service()" doesn't have such issue. and also it works well with docker 17.xx.

Below API level 1.25 Networks was specified on the Spec, not on the TaskTemplate.

This change moves the Network back to Spec before invoking the service create/update endpoints.

Thanks!

Signed-off-by: Viktor Adam <rycus86@gmail.com>
@shin- shin- added this to the 2.8.0 milestone Jan 12, 2018
@shin-
Copy link
Contributor

shin- commented Jan 12, 2018

LGTM, thank you!

@shin- shin- merged commit a28b9ff into docker:master Jan 12, 2018
@shin- shin- modified the milestones: 2.8.0, 3.0 Jan 26, 2018
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.

2 participants