Our most recently launched nodes' agents are crashing at startup with:
File "/usr/share/scalyr-agent-2/py/scalyr_agent/builtin_monitors/docker_monitor.py
class DockerClient(docker.APIClient): # pylint: disable=no-member
AttributeError: 'module' object has no attribute 'APIClient'
We can reproduce the AttributeError on the nodes with:
# python2
Python 2.7.16 (default, Dec 12 2019, 23:58:22)
[GCC 7.3.1 20180712 (Red Hat 7.3.1-6)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import docker
>>> docker.APIClient
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
AttributeError: 'module' object has no attribute 'APIClient'
We can also reproduce the AttributeError with this Dockerfile, which installs Scalyr Agent 2 the way we installed it on the nodes and then runs the Python code above:
docker build -t scalyr-agent-2-test .
docker run --rm -ti scalyr-agent-2-test