This type is only used by CLI code. It duplicates SecretReference in the
types/swarm package. Change the CLI code to use that type instead.
Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
Upstream-commit: e7c39f4d5d761f68e6ac432934d8c3910e452855
Component: engine
This fix tries to address the request in 31325 by adding
`--filter mode=global|replicated` to `docker service ls`.
As `docker service ls` has a `MODE` column by default, it is natural
to support `--filter mode=global|replicated` for `docker service ls`.
There are multiple ways to address the issue. One way is to pass
the filter of mode to SwarmKit, another way is to process the filter
of mode in the daemon.
This fix process the filter in the daemon.
Related docs has been updated.
An integration test has been added.
This fix fixes 31325.
Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
Upstream-commit: 43a1bd564b5dbd835631cda102f68286c0d533e9
Component: engine
… as we don't know for sure what API version it will be at that time.
Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Upstream-commit: 0f9d22cd66353b3d14dd4a08084f88778fb69480
Component: engine
Add verbose flag to network inspect to show all services & tasks in swarm mode
Upstream-commit: cdf66ba715c573f85338a2b2a432db6cb9a48e6d
Component: engine
In https://github.com/torvalds/linux/commit/5ca3726 (released in v4.7-rc1) the
content of the `cpuacct.usage_percpu` file in sysfs was changed to include both
online and offline cpus. This broke the arithmetic in the stats helpers used by
`docker stats`, since it was using the length of the PerCPUUsage array as a
proxy for the number of online CPUs.
Add current number of online CPUs to types.StatsJSON and use it in the
calculation.
Keep a fallback to `len(v.CPUStats.CPUUsage.PercpuUsage)` so this code
continues to work when talking to an older daemon. An old client talking to a
new daemon will ignore the new field and behave as before.
Fixes#28941.
Signed-off-by: Ian Campbell <ian.campbell@docker.com>
Upstream-commit: 115f91d7575d6de6c7781a96a082f144fd17e400
Component: engine
Running the rm command on a paused/restarting container
will give an error message saying the container is running
which is incorrect.
To fix that, the error message will have the correct
container state and a procedure to remove it accordingly.
Notice: docker-py was bumped to:
4a08d04aef0595322e1b5ac7c52f28a931da85a5
Signed-off-by: Boaz Shuster <ripcurld.github@gmail.com>
Upstream-commit: 0ec8f56a3d7f1413cdb3ae7711d518e99f9282e9
Component: engine
Server-side rollback can take advantage of the rollback-specific update
parameters, instead of being treated as a normal update that happens to
go back to a previous version of the spec.
Signed-off-by: Aaron Lehmann <aaron.lehmann@docker.com>
Upstream-commit: f9bd8ec8b268581f93095c5a80679f0a8ff498bf
Component: engine
This adds 'consistency' mode flags to the mount command line argument.
Initially, the valid 'consistency' flags are 'consistent', 'cached',
'delegated', and 'default'.
Signed-off-by: David Sheets <dsheets@docker.com>
Signed-off-by: Jeremy Yallop <yallop@docker.com>
Upstream-commit: f13297c0beaf4fcc6742a9f3c047cbfeef955ac1
Component: engine
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: 17288c611a4f3f75ecb3bbb4533820b1836c55a6
Component: engine
text does not appear to contain a placeholder
Signed-off-by: Helen Xie <chenjg@harmonycloud.cn>
Upstream-commit: 2a8d6368d4a930203b93f75914173ab65bf3b0bc
Component: engine
This fix is an attempt to improve the documentation of
`Version` usage for Swarm API in Swagger docs.
As is shown in the docs updates, `Version` field in Swarm
API is a way to ensure safe concurrency and determinism
so that multiple updates to the same swarm related objects
(Node, Service, etc) will not unintentially overwrite each other.
This fix fixes 29448.
Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
Upstream-commit: 61e3e80b63f697d79665914a23e449fb94e3b678
Component: engine
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: c2d49ec214649b0025f7060429334893350fbaee
Component: engine
This fix tries to address the issue in 31179 where
secrets fields is missing for `docker service create`
or `docker service update`.
This fix adds Secrets for `ContainerSpec` in Swagger docs.
This fix fixes 31179.
Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
Upstream-commit: 7e6ce7c1768335600abc82a2fe933f19af70bad4
Component: engine
PR #31197 made me think I needed to add more text explaing why
BuildArgs needs to be a *string instead of string.
Signed-off-by: Doug Davis <dug@us.ibm.com>
Upstream-commit: 9419ccd706feee0531d63ec3b517f97104b5177f
Component: engine
This fix adds the missing fields of `Hostname`, `OpenStdin`,
`Hosts`, `Groups`, and `Healthcheck` to `ContainerSpec`.
This fix also moves the `Label` in `ContainerSpec` to align with
the definition order.
Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
Upstream-commit: 897e69143a15bbf5f4efe91664e3de2aba7264a1
Component: engine
These errors were producing the wrong status code,
changing to 503.
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
Upstream-commit: 7e44fffe40f39ef4cc0b3bee810f7d0a26136376
Component: engine