ansible / ansible-container

DEPRECATED -- Ansible Container was a tool to build Docker images and orchestrate containers using only Ansible playbooks.
GNU Lesser General Public License v3.0
2.19k stars 392 forks source link

Python Docker client 3.0 breaking change #869

Closed marcusianlevine closed 6 years ago

marcusianlevine commented 6 years ago
ISSUE TYPE
SUMMARY

Version 3.0.0 of the Python docker client was released last night which seems to have broken the conductor build process.

All of our ansible-container projects are failing to build this morning.

Pinning docker below 3.0 resolved the issue.

STEPS TO REPRODUCE

Force installation of new docker client: pip install -U ansible-container

Build any container project with --no-cache

EXPECTED RESULTS

Containers build as usual

ACTUAL RESULTS

Conductor fails to build

Building Docker Engine context...   
Starting Docker build of Ansible Container Conductor image (please be patient)...   
Post stage
ERROR   Unknown exception   
Traceback (most recent call last):
  File "/usr/local/lib/python2.7/site-packages/container/cli.py", line 299, in __call__
    getattr(core, u'hostcmd_{}'.format(args.subcommand))(**vars(args))
  File "/usr/local/lib/python2.7/site-packages/container/__init__.py", line 28, in __wrapped__
    return fn(*args, **kwargs)
  File "/usr/local/lib/python2.7/site-packages/container/core.py", line 181, in hostcmd_build
    environment=env_vars
  File "/usr/local/lib/python2.7/site-packages/container/docker/engine.py", line 105, in __wrapped__
    return fn(self, *args, **kwargs)
  File "/usr/local/lib/python2.7/site-packages/container/__init__.py", line 28, in __wrapped__
    return fn(*args, **kwargs)
  File "/usr/local/lib/python2.7/site-packages/container/docker/engine.py", line 1070, in build_conductor_image
    return image.id
AttributeError: 'tuple' object has no attribute 'id'