Commit Graph

1807 Commits

Author SHA1 Message Date
145eac88d4 Merge pull request #20835 from cpuguy83/handle_stats_client_errors
Do not remove containers from stats list on err
Upstream-commit: 5314296c693d0d4d7f622940b48bc15e400032e3
Component: engine
2016-04-16 10:20:58 +01:00
8d9f1bcb22 Merge pull request #21939 from calavera/events_until_past
Get events until a time in the past.
Upstream-commit: 19a453e6b40177af31703f107131aae5ca81adf2
Component: engine
2016-04-15 15:33:41 -04:00
de95cbad37 Get events until a time in the past.
This change allow to filter events that happened in the past
without waiting for future events. Example:

docker events --since -1h --until -30m

Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: 55053d3537100eaeaad9c83b43e31f22d14fde7b
Component: engine
2016-04-14 16:22:16 -07:00
90af4a019b Do not remove containers from stats list on err
Before this patch, containers are silently removed from the stats list
on error. This patch instead will display `--` for all fields for the
container that had the error, allowing it to recover from errors.

Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Upstream-commit: ff08036cc0d1b393106570a8c141e909d894f7d3
Component: engine
2016-04-13 16:36:34 -04:00
da8ff9f6e7 Merge pull request #21959 from coolljt0725/fix_21957
Fix docker load progressbar, fixes #21957
Upstream-commit: 348d90276802aac6c76126f2fe6866c521190ecd
Component: engine
2016-04-13 00:31:27 -04:00
94711fe63a Fix docker load progressbar, fixes #21957
Signed-off-by: Lei Jitang <leijitang@huawei.com>
Upstream-commit: 96d7db665b06cc0bbede22d818c69dc5f6921f66
Component: engine
2016-04-12 22:45:42 -04:00
e1986078c7 Merge pull request #21897 from calavera/remove_authorization_refs_from_api
Move middleware to interfaces.
Upstream-commit: 9438572fc00f928ec83c884992d5492a7a68babb
Component: engine
2016-04-12 14:08:36 -07:00
8194e834c4 Move middleware to interfaces.
This makes separating middlewares from the core api easier.
As an example, the authorization middleware is moved to
it's own package.

Initialize all static middlewares when the server is created, reducing
allocations every time a route is wrapper with the middlewares.

Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: 8d3467626ee26cad48ad84f2181552dce7afccb6
Component: engine
2016-04-11 09:19:27 -07:00
a5c656d2b9 Change HumanSize to BytesSize for memory output in docker stats.
This fix tries to fix the discrepancy between `docker stats` and
`docker run` where `docker run` uses RAMInBytes for all memory
related inputs but `docker stats` uses HumanSize for all memory
related outputs.

To be consistent, `docker stats` needs to use BytesSize for all
memory related outputs to conform to RAMInBytes in `docker run`.

This fix addresses this issue. As BytesSize is used, the test
cases needs to be adjusted to match `KiB/MiB/GiB` instead of
`KB/MB/GB`.

The documentation has also been updated.

This fix fixes #21765.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
Upstream-commit: 0e3846e280195cb47c47a7739b475b281dd301cb
Component: engine
2016-04-08 20:01:50 +00:00
956e3c675e Remove reference package dependency from the api.
Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: 47afe6bd0a0dc806c36d0978a8d3e23f75ef87fe
Component: engine
2016-04-07 15:01:23 -07:00
5da6bec3ad Merge pull request #21092 from WeiZhang555/fix-21064-detach-keys
Client print error when specify wrong detach keys
Upstream-commit: 5709f8e4227e0e1da333739c44003a3f47279bd5
Component: engine
2016-04-06 22:14:14 +02:00
0dfaed7e71 do not trim one char from {{.Names}} each time it is used in --format
Signed-off-by: Victor Vieux <vieux@docker.com>
Upstream-commit: 68ade49adab15429168903f5600ab64ce7f7c8c5
Component: engine
2016-04-06 11:04:13 -07:00
97016757fb Let client print error when speicify wrong detach keys
Fix #21064

Let client print error message explicitly when user specifies wrong
detach keys.

Signed-off-by: Zhang Wei <zhangwei555@huawei.com>
Upstream-commit: 91e5bb954131904af150b06bd22b007559a8ce27
Component: engine
2016-04-04 15:35:55 +08:00
92dc3a4465 Fixing help text of "docker network --help" to be consistend
Changed from hashmap to multidimensional array as in "docker volume --help"
closes #21710

Signed-off-by: Robin Naundorf <r.naundorf@fh-muenster.de>
Upstream-commit: 737219bbdbd5c18a2f581c73ac740ea44266b82b
Component: engine
2016-04-01 14:14:09 +02:00
0d08181d47 Merge pull request #20410 from tkopczynski/20236-info-insecure-registry
Add insecure registries to docker info
Upstream-commit: 4a7bd7eaef0038b006cf23adface84081e5aab3b
Component: engine
2016-03-31 16:39:25 -07:00
da61313bb3 Merge pull request #21693 from cyli/fix-trusted-build-and-run
Request pull credentials when using trusted reference
Upstream-commit: f19f91d0da710b45603e1f3b95a3709c57cd888a
Component: engine
2016-03-31 16:35:06 -04:00
71d4646a90 Request pull credentials when using trusted reference
Signed-off-by: cyli <cyli@twistedmatrix.com>
Upstream-commit: df9cc3d9228cb07474dd046736c6f83513c4923d
Component: engine
2016-03-31 10:56:19 -07:00
7497562d8e Fix race between with event timer stopping early
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
Upstream-commit: b38cee9f9c79d1f12001348303b78462d99664ed
Component: engine
2016-03-31 09:49:07 -07:00
58855775ca Add insecure registries to docker info
Signed-off-by: Tomasz Kopczynski <tomek@kopczynski.net.pl>
Upstream-commit: 44a50abe7b16368bdc8b70e01cb095dc46cbbbaf
Component: engine
2016-03-31 08:27:24 +02:00
b960646c00 Remove builder dependency from the api.
Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: d12b7c7e3e5566f49f81189b757bcd0e4ef09956
Component: engine
2016-03-29 17:02:36 -07:00
922dd0a9e8 Merge pull request #21586 from calavera/remove_runconfig_from_routes
Remove runconfig package dependency from the API.
Upstream-commit: 1da40fb4badd116a7591dd2c19009146770c9a89
Component: engine
2016-03-29 08:40:49 -07:00
56103ffaad Remove runconfig package dependency from image and container routers.
Use an interface to specify the behavior of a configuration decoder.

Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: f0d26e1665f7552972db5b041554cc7b45bc3060
Component: engine
2016-03-28 16:23:51 -04:00
91e6a2df59 Remove runconfig dependency from network routes.
Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: 3ca29823d42ab1e2b1ea76981ccc9aa11e858cb2
Component: engine
2016-03-28 16:23:50 -04:00
1660794bad Merge pull request #21523 from LK4D4/cancellable_routes
Embed context.Context to routes with usage of CloseNotify
Upstream-commit: be390c30cdde978ea1a5417875876e4f3ae52655
Component: engine
2016-03-28 12:44:07 -07:00
4d49388b9b Merge pull request #21566 from allencloud/upper-case-docker-info-display
upper case docker info details
Upstream-commit: dd7691423f685bc4d724224913556c7e2cf4bc56
Component: engine
2016-03-28 11:37:23 -07:00
64bbcab7a5 upper case docker info details
Signed-off-by: allencloud <allen.sun@daocloud.io>
Upstream-commit: 276a20dd426524c254e8b2a4cc9047bcc62fd321
Component: engine
2016-03-28 18:47:04 +08:00
406cc47308 use router.Cancellable for pull and push
Signed-off-by: Alexander Morozov <lk4d4@docker.com>
Upstream-commit: c6ad1980a2eb2994940bdf7f79835ffdbed2b44d
Component: engine
2016-03-27 21:53:25 -07:00
ccb887dc36 Extend Docker authorization with TLS user information
Currently Docker authorization framework does not use any user
information, which already available in the Docker context for TLS
connection.
The purpose of this CR is to complete the existing authz work by adding
the basic client certificate details (SUBJECT_NAME) and authentication
method (TLS) to the authz request.

We think this should be the default behavior when no extended
authorization module is specified (currently WIP under #20883).

Signed-off-by: Liron Levin <liron@twistlock.com>
Upstream-commit: 3c157713b31f542a4180e31da4cae7d677330a6f
Component: engine
2016-03-27 15:53:55 +03:00
ecee852fa8 Merge pull request #21508 from vdemeester/remove-client-unused-method
Removing DockerCli.pullImage as it's never used
Upstream-commit: 0524a9783d5210bf3e24794fb9a81c256393b83b
Component: engine
2016-03-25 13:52:49 -07:00
4948749e40 use router.Cancellable instead of direct CloseNotify
Signed-off-by: Alexander Morozov <lk4d4@docker.com>
Upstream-commit: 62c9e62edcf3d96d251fd06a48437b2fa2f56ad6
Component: engine
2016-03-25 11:33:54 -07:00
f7d7f8e5e6 Merge pull request #21468 from coolljt0725/remove_useless_log
Do not return error on hijacked connection for docker exec
Upstream-commit: e2221d1f37d1204ccca51722aa21fc11939a41ba
Component: engine
2016-03-25 10:50:43 -07:00
96f77f179c api/server/router: add Cancellable function
Signed-off-by: Alexander Morozov <lk4d4@docker.com>
Upstream-commit: bdd9388c4262d228c57ce637a8e6fad003684df1
Component: engine
2016-03-25 10:19:23 -07:00
f866264ba4 Removing DockerCli.pullImage as it's never used
This function is never used nor exported. It has been superseeded by
pullImageCustomOut.

Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Upstream-commit: 8f4b7a33617534dea29c0b61ee93225b9c998a7c
Component: engine
2016-03-25 17:41:19 +01:00
43dd16ffb4 builder: replace cancelled channel with net/context
Also stop execution of run immediately if request was cancelled.

Signed-off-by: Alexander Morozov <lk4d4@docker.com>
Upstream-commit: f2401a0f6960734093be307a27bba85a3c2ecfcd
Component: engine
2016-03-25 08:19:29 -07:00
d30f94de1d Merge pull request #20589 from coolljt0725/fix_restore_terminal
cli: move setRawTerminal and restoreTerminal to holdHijackedConnection
Upstream-commit: 641bd7652f0f65712bab60f7a5f8e299dcb5643c
Component: engine
2016-03-24 22:42:24 -07:00
eeff19f114 cli: move setRawTerminal and restoreTerminal to holdHijackedConnection
In this way, we can restore the Terminal as soon as possible once the hijacked
connection end. This not only fix weird output if cli enable -D, but also
remove duplicate code.

Signed-off-by: Lei Jitang <leijitang@huawei.com>
Upstream-commit: 66d3dcc6f7648ab5af3c7f876c2b9c63ab2899ac
Component: engine
2016-03-24 21:25:50 -04:00
d3972744c1 Merge pull request #21456 from calavera/remove_unecessary_hardcoded_version
Remove unnecessary hardcoded version.
Upstream-commit: 6748ecb0050f2c6a9a57e824f23b5b4afb35240d
Component: engine
2016-03-24 14:31:59 -07:00
1a8e9b8519 Merge pull request #21464 from coolljt0725/cleanup_dot
Cleanup: remove redundant period
Upstream-commit: 2b6b2e1af853d465d22f5a57e71aea89852340eb
Component: engine
2016-03-24 18:34:20 +01:00
2257ef7e0a Remove unnecessary hardcoded version.
The server configuration already keeps the current version
if the daemon. This patch changes the middleware logic
to use it rather than using the global value.

This removes the dockerversion package dependency from the api.

Signed-off-by: David Calavera <david.calavera@gmail.com>
Upstream-commit: accf28a7dbdd46203c661d30b80326df4d447cea
Component: engine
2016-03-24 12:33:40 -04:00
afd62f19a9 Do not return error on hijacked connection for docker exec
Signed-off-by: Lei Jitang <leijitang@huawei.com>
Upstream-commit: d6ccc0e09fe42d9f0d929dbf8d68ce790f4c8b9e
Component: engine
2016-03-24 08:52:13 -04:00
95256bc90a Cleanup: remove redundant period
Signed-off-by: Lei Jitang <leijitang@huawei.com>
Upstream-commit: cb5b8767b6988855daa1a264202be929c24c6177
Component: engine
2016-03-24 08:26:04 -04:00
6cee95ae99 Merge pull request #21268 from calavera/remove_dockerfile_from_api
Remove dockerfile dependency from the API.
Upstream-commit: 5ef04b1c6d1ca94c83c7ce52faae908a278ce6ea
Component: engine
2016-03-23 19:34:21 -07:00
91408a7472 Bump API Version to v1.24
Signed-off-by: Tibor Vass <tibor@docker.com>
Upstream-commit: 928ea1e957812c351b77bb33be7f3ef9fd629231
Component: engine
2016-03-23 12:26:23 -04:00
0436cacd63 Merge pull request #21406 from LK4D4/fix_streams_race
builder: synchronize stderr and stdout
Upstream-commit: fb1365639e7be8bb5e114de0b28e4a22c01530ee
Component: engine
2016-03-22 17:15:01 -07:00
2e2ed4c31e Merge pull request #21303 from riyazdf/notary-vendor-docker1.11
vendor notary for docker1.11
Upstream-commit: 8b8fcb796f85bc8f5146fa61ce667699f0436591
Component: engine
2016-03-22 17:57:17 -04:00
fd6a3ad797 builder: synchronize stderr and stdout
it's concurrent streams and should be synchronized before writing to response.
Otherwise there will be race in writing to *bufio.Writer in
net/http.response.

Signed-off-by: Alexander Morozov <lk4d4@docker.com>
Upstream-commit: 3eb0a80f29629a1c022dc914437b176271d476fc
Component: engine
2016-03-22 13:57:29 -07:00
02220a45c4 Merge pull request #21270 from ehazlett/resource-labels
Add Label support for Images (build), Networks and Volumes on Creation
Upstream-commit: 53d2e5e9d754ce8fbef733759e9ec450514133e3
Component: engine
2016-03-22 15:12:33 -04:00
20a8382c82 vendor notary for docker1.11
Signed-off-by: Riyaz Faizullabhoy <riyaz.faizullabhoy@docker.com>
Upstream-commit: ab3772f72fcb189c742510326069474ea625042f
Component: engine
2016-03-22 11:28:19 -07:00
fe56b4ef22 add label support for build, networks and volumes
build: implement --label

Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>

network: allow adding labels on create

Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>

volume: allow adding labels on create

Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>

add tests for build, network, volume

Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>

vendor: libnetwork and engine-api bump

Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
Upstream-commit: fc214b4408d915e3510f61c7584ca01c176d1373
Component: engine
2016-03-22 11:49:06 -04:00
288aa38b5e Merge pull request #21046 from cyli/use-notary-cli
Sign all first-level delegation roles when doing a trusted push
Upstream-commit: 666563b190b7c97dc9db334ef03768ee8432b20e
Component: engine
2016-03-22 07:42:21 +01:00