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

hide `--detach` for docker < 17.05 #219

Merged
merged 1 commit into from Jun 27, 2017

Conversation

Projects
None yet
6 participants
@vieux
Contributor

vieux commented Jun 21, 2017

1st I added --detach to docker service scale
then while testing I realized that using docker 17.05 with a 17.03 client doesn't work with --detach=true since it's using an unknown filter to 17.03. so I hid the flag (as it should have been)

@vieux

This comment has been minimized.

Show comment
Hide comment
@vieux

vieux Jun 21, 2017

Contributor

Here is the current behavior:

$docker service update --replicas=8 test
test
Since --detach=false was not specified, tasks will be updated in the background.
In a future release, --detach=false will become the default.

When adding the flag as suggested:

$docker service update --detach=false --replicas=8 test
test
Error response from daemon: Invalid filter '_up-to-date'
Contributor

vieux commented Jun 21, 2017

Here is the current behavior:

$docker service update --replicas=8 test
test
Since --detach=false was not specified, tasks will be updated in the background.
In a future release, --detach=false will become the default.

When adding the flag as suggested:

$docker service update --detach=false --replicas=8 test
test
Error response from daemon: Invalid filter '_up-to-date'
@vieux

This comment has been minimized.

Show comment
Hide comment
@vieux

vieux Jun 21, 2017

Contributor

ping @thaJeztah

Contributor

vieux commented Jun 21, 2017

ping @thaJeztah

@codecov-io

This comment has been minimized.

Show comment
Hide comment
@codecov-io

codecov-io Jun 21, 2017

Codecov Report

Merging #219 into master will increase coverage by 0.03%.
The diff coverage is 55%.

@@            Coverage Diff             @@
##           master     #219      +/-   ##
==========================================
+ Coverage   46.81%   46.85%   +0.03%     
==========================================
  Files         172      172              
  Lines       11686    11689       +3     
==========================================
+ Hits         5471     5477       +6     
+ Misses       5903     5900       -3     
  Partials      312      312

codecov-io commented Jun 21, 2017

Codecov Report

Merging #219 into master will increase coverage by 0.03%.
The diff coverage is 55%.

@@            Coverage Diff             @@
##           master     #219      +/-   ##
==========================================
+ Coverage   46.81%   46.85%   +0.03%     
==========================================
  Files         172      172              
  Lines       11686    11689       +3     
==========================================
+ Hits         5471     5477       +6     
+ Misses       5903     5900       -3     
  Partials      312      312
Show outdated Hide outdated cli/command/service/scale.go Outdated
Show outdated Hide outdated cli/command/service/scale.go Outdated
Show outdated Hide outdated cli/command/service/scale.go Outdated
Show outdated Hide outdated cli/command/service/scale.go Outdated

@thaJeztah thaJeztah added this to the 17.06.1 milestone Jun 24, 2017

@dnephin

I wouldn't worry about the rest of the test coverage for this change. The coverage should come when unit tests are written for the service commands.

Show outdated Hide outdated cli/command/service/scale.go Outdated
Show outdated Hide outdated cli/command/service/opts.go Outdated
Show outdated Hide outdated cli/command/service/helpers_test.go Outdated

@vieux vieux changed the title from add `--detach` to `docker service scale` and fix 17.05 -> 17.03 to hide `--detach` for docker < 17.05 Jun 27, 2017

@vieux

This comment has been minimized.

Show comment
Hide comment
@vieux

vieux Jun 27, 2017

Contributor

split the PR in two, here is the bugfix/refactor, new feature in #243

Contributor

vieux commented Jun 27, 2017

split the PR in two, here is the bugfix/refactor, new feature in #243

@docker docker deleted a comment from thaJeztah Jun 27, 2017

hide --detach for docker < 17.05
Signed-off-by: Victor Vieux <victorvieux@gmail.com>
@thaJeztah

LGTM

@tiborvass

This comment has been minimized.

Show comment
Hide comment
@tiborvass

tiborvass Jun 27, 2017

Contributor

LGTM

Contributor

tiborvass commented Jun 27, 2017

LGTM

@tiborvass tiborvass merged commit c3e5445 into docker:master Jun 27, 2017

7 checks passed

ci/circleci: cross Your tests passed on CircleCI!
Details
ci/circleci: lint Your tests passed on CircleCI!
Details
ci/circleci: test Your tests passed on CircleCI!
Details
ci/circleci: validate Your tests passed on CircleCI!
Details
codecov/patch 55% of diff hit (target 50%)
Details
codecov/project 46.85% (+0.03%) compared to 0133e13
Details
dco-signed All commits are signed

@vieux vieux deleted the vieux:scale branch Jun 27, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment