Commit Graph

108 Commits

Author SHA1 Message Date
3803869429 Replace environmental with environment
Signed-off-by: Nir Soffer <nsoffer@redhat.com>
(cherry picked from commit f1f3d3be17)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: 4c94a0af75
Component: cli
2019-03-18 11:15:43 +01:00
ea934f5313 Add --init option to docker service create
Signed-off-by: Timothy Higinbottom <timhigins@gmail.com>
Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Upstream-commit: ff13f03def
Component: cli
2018-06-14 13:50:12 +02:00
faa59fb288 docs: mention sctp
Signed-off-by: Akihiro Suda <suda.akihiro@lab.ntt.co.jp>
Upstream-commit: b85d87b8ab
Component: cli
2018-02-26 15:27:11 +09:00
acea77d537 Merge pull request #843 from sepich/docs-for-pr33130
Document long form of --network and --network-add
Upstream-commit: 84c7dd6057
Component: cli
2018-02-21 23:26:39 +01:00
d9b7b3fed0 Document service --network long form
Signed-off-by: Alexander Ryabov <i@sepa.spb.ru>
Upstream-commit: 94ecd2ba73
Component: cli
2018-02-16 09:34:42 +03:00
dc47308ffd Add an example for --with-registry-auth
Signed-off-by: Misty Stanley-Jones <misty@docker.com>
Upstream-commit: 821452629c
Component: cli
2018-01-31 13:38:49 -08:00
d0e1c8724c Fix the network option table
Signed-off-by: Misty Stanley-Jones <misty@docker.com>
Upstream-commit: 773ccdec7b
Component: cli
2018-01-30 14:00:48 -08:00
Kat
e4754a59e3 Correct table html with close tag for </thead>
Signed-off-by: Kat Samperi <kat.samperi@gmail.com>
Upstream-commit: 57372d18ca
Component: cli
2018-01-04 15:01:28 +00:00
467a8bb243 Correct references to --publish long syntax in docs
This is the same issue as described at docker/docker.github.io#5370

Signed-off-by: Lachlan Cooper <lachlancooper@gmail.com>
Upstream-commit: 90f44e564b
Component: cli
2017-12-13 10:25:43 +11:00
025793bb76 Added docs for service create
Signed-off-by: Renaud Gaubert <renaud.gaubert@gmail.com>
Upstream-commit: 4a6da88f7a
Component: cli
2017-11-28 18:03:10 +01:00
f9712fa620 Merge pull request #426 from simonferquel/service-isolation
--isolation for setting swarm service isolation mode
Upstream-commit: 5e2be6584a
Component: cli
2017-11-17 15:39:43 +01:00
c5471a4a0e Add isolation mode on service update/create and compose files
Signed-off-by: Simon Ferquel <simon.ferquel@docker.com>
Upstream-commit: 47cf2ea683
Component: cli
2017-11-17 15:31:13 +01:00
f78101e94a Add info about new port mapping syntax
Signed-off-by: Misty Stanley-Jones <misty@docker.com>
Upstream-commit: 9ef7caa6fe
Component: cli
2017-11-15 17:58:13 -08:00
d77f572b3a Remove extra spaces from service creation examples
Signed-off-by: Misty Stanley-Jones <misty@docker.com>
Upstream-commit: 80211acee9
Component: cli
2017-11-10 10:14:56 -08:00
70aedb437f fix a number of minor typos
Fix 19 typos, grammatical errors and duplicated words.

These fixes have minimal impact on the code as these are either in the
doc files or in comments inside the code files.

Signed-off-by: Abdur Rehman <abdur_rehman@mentor.com>
Upstream-commit: c3fe9d85ef
Component: cli
2017-10-31 15:21:51 +05:00
afca8202d7 Fix markdown link in service-create reference docs
Markdown nested in a HTML table doesn't work, so changing
the link to a plain HTML link.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: 6b6511f191
Component: cli
2017-10-05 12:17:40 +02:00
ab0a17f568 Fix GitHub spelling
Signed-off-by: Frieder Bluemle <frieder.bluemle@gmail.com>
Upstream-commit: 45c9b9b6c1
Component: cli
2017-10-05 01:14:31 +08:00
6daf6c2b58 Fix service_create markdown
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: 01ef9acd31
Component: cli
2017-09-19 16:29:52 +02:00
a5b24016fd Document .Node.Hostname templating
Update placeholders table and add example code
Follow up to moby/moby#34686

Signed-off-by: Carlo Mion <mion00@gmail.com>
Upstream-commit: 21825b6842
Component: cli
2017-09-15 10:23:56 +02:00
31162a9a25 Dropped hyphen in bind mount where appropriate
Signed-off-by: Christophe Vidal <kriss@krizalys.com>
Upstream-commit: 037029414d
Component: cli
2017-08-19 21:14:48 +07:00
43172bf261 Merge pull request #205 from redpanda/rollback
Add 'docker service rollback' subcommand
Upstream-commit: 3c7ede6a68
Component: cli
2017-08-19 15:56:14 +02:00
cded911aad Add 'docker service rollback' subcommand
Signed-off-by: Jimmy Leger <jimmy.leger@gmail.com>

Implement runRollback to not use runUpdate

Signed-off-by: Jimmy Leger <jimmy.leger@gmail.com>

Add version tag and add flag quiet to suppress progress output

Signed-off-by: Jimmy Leger <jimmy.leger@gmail.com>

Removed flags from warnDetachDefault

Signed-off-by: Jimmy Leger <jimmy.leger@gmail.com>

Used command.Cli interface

Signed-off-by: Jimmy Leger <jimmy.leger@gmail.com>

Add detach flag on rollback command

Signed-off-by: Jimmy Leger <jimmy.leger@gmail.com>

Create a fakeClient for service commands

Signed-off-by: Jimmy Leger <jimmy.leger@gmail.com>

Added unit test for rollback command

Signed-off-by: Jimmy Leger <jimmy.leger@gmail.com>

Used command.Cli interface instead of *command.DockerCli in service commands

Signed-off-by: Jimmy Leger <jimmy.leger@gmail.com>

Revert "Removed flags from warnDetachDefault"

This reverts commit 3e4f601c8a82cc2599a755dc693409bbc47917fc.

Signed-off-by: Jimmy Leger <jimmy.leger@gmail.com>

Fixed test.NewFakeCli instanciation

Signed-off-by: Jimmy Leger <jimmy.leger@gmail.com>

Removed unused receiver

Signed-off-by: Jimmy Leger <jimmy.leger@gmail.com>

Replaced cli by dockerCli

Signed-off-by: Jimmy Leger <jimmy.leger@gmail.com>

Revert "Removed unused receiver"

This reverts commit 604ef7c13df3d019949ca81d992db501114dafce.

Signed-off-by: Jimmy Leger <jimmy.leger@gmail.com>

Fixed last typo

Signed-off-by: Jimmy Leger <jimmy.leger@gmail.com>
Upstream-commit: 11d471d660
Component: cli
2017-08-16 22:18:36 +02:00
457a3de5d9 Updated & reformulated kinds of mounts section
Signed-off-by: Christophe Vidal <kriss@krizalys.com>
Upstream-commit: 9c4b9c6f63
Component: cli
2017-08-17 00:51:35 +07:00
97a283fbdb update service create and update options in commandline documentation
Signed-off-by: zebrilee <zebrilee@gmail.com>
Upstream-commit: 5fe09164f5
Component: cli
2017-07-31 23:26:02 +02:00
c16c5f3db8 Fix repo references in docs
Since CLI was moved to a separate repo, these references are incorrect.
Fixed with the help of sed script, verified manually.

Signed-off-by: Kir Kolyshkin <kolyshkin@gmail.com>
Upstream-commit: 6d85a4f5f8
Component: cli
2017-07-28 10:32:42 -07:00
42cbae8c65 Service privileges: CLI reference docs & completion
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: 5cc7ac2990
Component: cli
2017-07-14 22:30:47 -07:00
017354f791 Provide examples for multiple uses of the same flag
Signed-off-by: Misty Stanley-Jones <misty@docker.com>
Upstream-commit: ef61582591
Component: cli
2017-07-03 16:21:28 -07:00
f54540bc34 do not allow duration less than 1 ms in healthcheck parameters
Signed-off-by: Dong Chen <dongluo.chen@docker.com>
Upstream-commit: 1fa8221743
Component: cli
2017-06-02 00:11:04 +00:00
af4c3ad361 Make the CLI show defaults from the swarmkit defaults package
If no fields related to an update config or restart policy are
specified, these structs should not be created as part of the service,
to avoid hardcoding the current defaults.

Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
Upstream-commit: 91ca194713
Component: cli
2017-06-02 00:11:03 +00:00
bf4beaf856 Add support for update order
This parameter controls the order of operations when rolling out an
update task. Either the old task is stopped before starting the new one,
or the new task is started first, and the running tasks will briefly
overlap.

This commit adds Rollout to the API, and --update-order / --rollback-order
flags to the CLI.

Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
Upstream-commit: e434a91221
Component: cli
2017-06-02 00:11:02 +00:00
429d548d41 Added start period option to health check.
Signed-off-by: Elias Faxö <elias.faxo@gmail.com>
Upstream-commit: c5071b94da
Component: cli
2017-06-02 00:11:02 +00:00
6d717fcaf7 fix documentation error: volume-opt in service create
Signed-off-by: pacoxu<paco.xu@daocloud.io>
Signed-off-by: pacoxu <paco.xu@daocloud.io>
Upstream-commit: 764c84342d
Component: cli
2017-06-02 00:11:01 +00:00
dc4ce81f2b Synchronous service create and service update
Change "service create" and "service update" to wait until the creation
or update finishes, when --detach=false is specified. Show progress bars
for the overall operation and for each individual task (when there are a
small enough number of tasks), unless "-q" / "--quiet" is specified.

Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
Upstream-commit: c8e607205f
Component: cli
2017-06-02 00:11:01 +00:00
71e8f665b9 Documentation for bind mount consistency flags.
Signed-off-by: Jeremy Yallop <yallop@docker.com>
Upstream-commit: a7c4324c47
Component: cli
2017-06-02 00:10:58 +00:00
10bab1af16 Merge pull request #31875 from toolchainX/patch-2
update service-create.md
(cherry picked from commit 0f1ee840143b230259544dbfc03205dafcd285ad)
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: 8dd6f6d342
Component: cli
2017-06-02 00:10:58 +00:00
eb0bef3819 misleading default for --update-monitor duration
Signed-off-by: erxian <evelynhsu21@gmail.com>
Upstream-commit: ffd24bd8e8
Component: cli
2017-06-02 00:10:58 +00:00
55f899c468 Fix markdown in references for Kramdown
Signed-off-by: Misty Stanley-Jones <misty@docker.com>
Upstream-commit: 1f531be8ab
Component: cli
2017-06-02 00:10:57 +00:00
33d9e6294f Add support for rollback flags
Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
Upstream-commit: 33ae729456
Component: cli
2017-06-02 00:10:56 +00:00
43638de628 Add support for the "rollback" failure action
Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
Upstream-commit: 8271c2a624
Component: cli
2017-06-02 00:10:56 +00:00
951746da22 Topology-aware scheduling
This adds support for placement preferences in Swarm services.

- Convert PlacementPreferences between GRPC API and HTTP API
- Add --placement-pref, --placement-pref-add and --placement-pref-rm to CLI
- Add support for placement preferences in service inspect --pretty
- Add integration test

Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
Upstream-commit: 0248b4df54
Component: cli
2017-06-02 00:10:56 +00:00
fec035ef1b remove Jekyll tags from CLI reference
These Markdown files are now embedded in a YAML
file for templating in the documentation, and
these special markers are no longer needed.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: 8e7dd976f8
Component: cli
2017-06-02 00:10:56 +00:00
ded0855252 Add --stop-signal for service create and service update
This fix tries to address the issue raised in 25696 where
it was not possible to specify `--stop-signal` for `docker service create`
and `docker service update`, in order to use special signal to stop
the container.

This fix adds `--stop-signal` and update the `StopSignal` in `Config`
through `service create` and `service update`.

Related docs has been updated.

Integration test has been added.

This fix fixes 25696.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
Upstream-commit: e9457714cf
Component: cli
2017-06-02 00:10:56 +00:00
2cc38cf538 fix the type
Signed-off-by: yupengzte <yu.peng36@zte.com.cn>
Upstream-commit: 6f3f9e384c
Component: cli
2017-06-02 00:10:55 +00:00
020523b38b Standardized formatting of CLI reference commands
Command name should be a H1

Only Description, Examples, and Related Commands should be H2

Changed 'Related information' heading to 'Related commands' since 99% it is only linking commands

Added some examples where relevant

Signed-off-by: Misty Stanley-Jones <misty@docker.com>
Upstream-commit: ddadd3db49
Component: cli
2017-06-02 00:10:53 +00:00
b802dfee3e add endpoint mode a default value
Signed-off-by: allencloud <allen.sun@daocloud.io>
Upstream-commit: 2726013423
Component: cli
2017-06-02 00:10:52 +00:00
2b3dc2cecc reference/commandline: small tfix
Signed-off-by: Ma Shimiao <mashimiao.fnst@cn.fujitsu.com>
Upstream-commit: e000321b1d
Component: cli
2017-06-02 00:10:52 +00:00
d0dc5b7b7d Update opts.MemBytes to disable default, and move docker run/create/build to use opts.MemBytes
This fix made several updates:
1. Update opts.MemBytes so that default value will not show up.
   The reason is that in case a default value is decided by daemon,
   instead of client, we actually want to not show default value.
2. Move `docker run/create/build` to use opts.MemBytes for `--shm-size`
   This is to bring consistency between daemon and docker run
3. docs updates.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
Upstream-commit: d75f24fd9d
Component: cli
2017-06-02 00:10:52 +00:00
2a7cf7b5d0 Add --read-only for service create and service update
This fix tries to address the issue raised in 29972 where
it was not possible to specify `--read-only` for `docker service create`
and `docker service update`, in order to have the container's root file
system to be read only.

This fix adds `--read-only` and update the `ReadonlyRootfs` in `HostConfig`
through `service create` and `service update`.

Related docs has been updated.

Integration test has been added.

This fix fixes 29972.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
Upstream-commit: 8235af9772
Component: cli
2017-06-02 00:10:51 +00:00
ce90228a83 Fixed secret creation usage during service create in docs
Using source, the following error is made:
invalid field in secret request: src

Signed-off-by: Michael Irwin <mikesir87@gmail.com>
Upstream-commit: 6e6d6edd08
Component: cli
2017-06-02 00:10:50 +00:00
c462ad6f63 Fix misleading default for --replicas
This fix tries to address the issue raised in 29291 where
the output of `--replicas` in `service create/update`:
```
      --replicas uint                    Number of tasks (default none)
```
is misleading. User might incorrectly assume the number of replicas
would be `0` (`none`) by default, while the actual default is `1`.

The issue comes from the fact that some of the default values are
from daemon and it is not possible for client to find out the default
value.

In this case, it might be better to just simply not displaying `(default none)`.

This fix returns "" for `Uint64Opt` so that `(default none)` is hidden.

In addition to `--replicas`, this fix also changes
`--restart-delay`, `--restart-max-attempts`, `--stop-grace-period`,
`--health-interval`, `--health-timeout`, and `--restart-window`
in a similiar fashion.

New Output:
```
      --health-interval duration         Time between running the check (ns|us|ms|s|m|h)
      --health-timeout duration          Maximum time to allow one check to run (ns|us|ms|s|m|h)
...
      --replicas uint                    Number of tasks
...
      --restart-delay duration           Delay between restart attempts (ns|us|ms|s|m|h)
      --restart-max-attempts uint        Maximum number of restarts before giving up
      --restart-window duration          Window used to evaluate the restart policy (ns|us|ms|s|m|h)
...
      --stop-grace-period duration       Time to wait before force killing a container (ns|us|ms|s|m|h)
```

The docs has been updated. Note the docs for help output of `service create/update`
is out of sync with the current master. This fix replace with the update-to-date
help output.

This fix fixes 29291.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
Upstream-commit: 87b4281f62
Component: cli
2017-06-02 00:10:45 +00:00