aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTakayoshi Kimura <takayoshi@gmail.com>2017-05-22 10:45:13 +0900
committerBryn M. Reeves <bmr@redhat.com>2018-03-13 13:30:29 +0000
commit5f67a7f6cd532a4dea57a0c8ece51f1734ed8cbe (patch)
treeedfbefe1a9c7c03885ec4fce1acb1273e5e87bcd
parentef0f4b1ce83b090120b26b2eb496ecba6318ba20 (diff)
downloadsos-5f67a7f6cd532a4dea57a0c8ece51f1734ed8cbe.tar.gz
[docker] Enable log timestamp in docker logs
Enable docker logs -t option to make container troubleshooting easier. Container logs sometimes have different TZ timestapms without TZ info or no timestamps at all. Fixes: #1013 Signed-off-by: Takayoshi Kimura <tkimura@redhat.com> Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
-rw-r--r--sos/plugins/docker.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/sos/plugins/docker.py b/sos/plugins/docker.py
index 4f6c9882..50fdc9c2 100644
--- a/sos/plugins/docker.py
+++ b/sos/plugins/docker.py
@@ -99,7 +99,7 @@ class Docker(Plugin):
if self.get_option('logs'):
for container in insp:
self.add_cmd_output(
- "{0} logs {1}".format(
+ "{0} logs -t {1}".format(
self.docker_cmd,
container
)