DockerCLI/command/container
Yong Tang af80020ef2 Fix Windows `docker stats` showing Linux headers
This fix is an attempt to fix issue raised in #28005 where
`docker stats` on Windows shows Linux headers if there is
no containers in stats.

The reason for the issue is that, in case there is no container,
a header is faked in:
https://github.com/docker/docker/blob/v1.13.0/cli/command/formatter/formatter.go#L74-L78
which does not know OS type information (as OS was stored with container stat entries)

This fix tries to fix the issue by moving OS type information
to stats context (instead of individual container stats entry).

Additional unit tests have been added.

This fix fixes #28005.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
2017-02-05 08:55:30 -08:00
..
testdata Clean some stuff from runconfig that are cli only… 2016-12-24 13:16:00 +01:00
attach.go Minor cleanups in cli/command/container 2016-12-26 01:33:25 +01:00
cmd.go Minor cleanups in cli/command/container 2016-12-26 01:33:25 +01:00
commit.go Minor cleanups in cli/command/container 2016-12-26 01:33:25 +01:00
cp.go Minor cleanups in cli/command/container 2016-12-26 01:33:25 +01:00
create.go Merge pull request #30043 from dmcgowan/distribution-reference-update-1 2017-01-24 20:38:20 -08:00
diff.go Minor cleanups in cli/command/container 2016-12-26 01:33:25 +01:00
exec.go Merge pull request #29683 from vdemeester/runconfig-clean 2016-12-29 17:42:08 +01:00
exec_test.go Remove redundant parameter and fix typos 2016-11-10 11:05:31 +08:00
export.go Minor cleanups in cli/command/container 2016-12-26 01:33:25 +01:00
hijack.go Move image trust related cli methods into the image package. 2016-09-09 10:50:16 -04:00
inspect.go Minor cleanups in cli/command/container 2016-12-26 01:33:25 +01:00
kill.go Minor cleanups in cli/command/container 2016-12-26 01:33:25 +01:00
list.go Fix failure in `docker ps --format` when `.Label` has args 2017-01-23 09:31:48 -08:00
logs.go Merge pull request #29688 from tronicum/since-flag 2017-01-09 09:27:30 -05:00
opts.go Merge pull request #30203 from allencloud/validate-healthcheck-params-in-daemon-side 2017-02-01 21:19:30 -05:00
opts_test.go Update opts.MemBytes to disable default, and move `docker run/create/build` to use opts.MemBytes 2017-01-27 12:17:06 -08:00
pause.go Minor cleanups in cli/command/container 2016-12-26 01:33:25 +01:00
port.go Minor cleanups in cli/command/container 2016-12-26 01:33:25 +01:00
prune.go Add `--filter until=<timestamp>` for `docker container/image prune` 2017-01-04 14:16:42 -08:00
ps_test.go Use `map[string]bool` for `preProcessor` to ignore unknwon field 2016-11-16 13:23:47 -08:00
rename.go Minor cleanups in cli/command/container 2016-12-26 01:33:25 +01:00
restart.go Minor cleanups in cli/command/container 2016-12-26 01:33:25 +01:00
rm.go Minor cleanups in cli/command/container 2016-12-26 01:33:25 +01:00
run.go fix flag descriptions for content-trust 2017-01-23 14:52:36 +01:00
start.go Minor cleanups in cli/command/container 2016-12-26 01:33:25 +01:00
stats.go Fix Windows `docker stats` showing Linux headers 2017-02-05 08:55:30 -08:00
stats_helpers.go Merge pull request #29747 from xlgao-zju/break-the-for 2017-02-01 22:29:18 +01:00
stats_unit_test.go Update function name for TestCalculBlockIO 2016-11-09 17:43:10 +08:00
stop.go Minor cleanups in cli/command/container 2016-12-26 01:33:25 +01:00
top.go Minor cleanups in cli/command/container 2016-12-26 01:33:25 +01:00
tty.go Windows: OCI process struct convergence 2016-09-19 10:34:31 -07:00
unpause.go Minor cleanups in cli/command/container 2016-12-26 01:33:25 +01:00
update.go Add version annotation to various flags added in 1.13 2017-01-16 18:21:20 +01:00
utils.go Minor cleanups in cli/command/container 2016-12-26 01:33:25 +01:00
wait.go Minor cleanups in cli/command/container 2016-12-26 01:33:25 +01:00