From 153ce376bd04ce4fc8669a4fdbdf840a01edeb0b Mon Sep 17 00:00:00 2001 From: nicolargo Date: Mon, 14 Jun 2021 19:34:12 +0200 Subject: [PATCH] Docker containers information missing with Docker 20.10.x #1878 --- conf/glances.conf | 2 -- docs/aoa/docker.rst | 2 -- docs/man/glances.1 | 2 +- glances/__init__.py | 2 +- glances/plugins/glances_docker.py | 6 ++++-- 5 files changed, 6 insertions(+), 8 deletions(-) diff --git a/conf/glances.conf b/conf/glances.conf index ae71a0fc..85f4aa37 100644 --- a/conf/glances.conf +++ b/conf/glances.conf @@ -361,8 +361,6 @@ port_default_gateway=True [docker] disable=False -# Timeout for API calls (in seconds, default is 1) -timeout=1 # Only show specific containers (comma separeted list of container name or regular expression) # Comment this line to display all containers (default configuration) #show=telegraf diff --git a/docs/aoa/docker.rst b/docs/aoa/docker.rst index 87f2c8b8..c21dc850 100644 --- a/docs/aoa/docker.rst +++ b/docs/aoa/docker.rst @@ -21,8 +21,6 @@ under the ``[docker]`` section: [docker] disable=False - # Timeout for API calls (in seconds, default is 1) - timeout=1 # Only show specific containers (comma separeted list of container name or regular expression) show=thiscontainer,andthisone,andthoseones.* # Hide some containers (comma separeted list of container name or regular expression) diff --git a/docs/man/glances.1 b/docs/man/glances.1 index b5f5d3e7..354895bd 100644 --- a/docs/man/glances.1 +++ b/docs/man/glances.1 @@ -1,6 +1,6 @@ .\" Man page generated from reStructuredText. . -.TH "GLANCES" "1" "Jun 12, 2021" "3.2.0b2" "Glances" +.TH "GLANCES" "1" "Jun 14, 2021" "3.2.0b3" "Glances" .SH NAME glances \- An eye on your system . diff --git a/glances/__init__.py b/glances/__init__.py index 60337e2a..b09ca268 100644 --- a/glances/__init__.py +++ b/glances/__init__.py @@ -29,7 +29,7 @@ import sys # Global name # Version should start and end with a numerical char # See https://packaging.python.org/specifications/core-metadata/#version -__version__ = '3.2.0b2' +__version__ = '3.2.0b3' __author__ = 'Nicolas Hennion ' __license__ = 'LGPLv3' diff --git a/glances/plugins/glances_docker.py b/glances/plugins/glances_docker.py index 93545084..e3791424 100644 --- a/glances/plugins/glances_docker.py +++ b/glances/plugins/glances_docker.py @@ -137,8 +137,10 @@ class Plugin(GlancesPlugin): def connect(self): """Connect to the Docker server.""" try: - ret = docker.from_env(timeout=int(self.get_conf_value('timeout', - default='1'))) + # If the following line replace the next one, the issue #1878 + # is reproduced (Docker containers information missing with Docker 20.10.x) + # So, for the moment disable the timeout option + ret = docker.from_env() except Exception as e: logger.error("docker plugin - Can not connect to Docker ({})".format(e)) ret = None