Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Installing molecule[docker] does not bring all dependencies with Ansible-Core. #3208

Closed
rjeffman opened this issue Aug 24, 2021 · 2 comments
Closed
Labels

Comments

@rjeffman
Copy link

Issue Type

  • Bug report

Molecule and Ansible details

  • ansible-core-2.11.4
  • molecule-3.4.0
  • molecule_docker-0.2.4

Molecule installation method (one of):

  • pip

Ansible installation method (one of):

  • pip

Desired Behavior

When installing molecule[docker] through pip, along with Ansible-core 2.11, all required dependencies should also be installed.

Actual Behaviour

It seems that docker_login is used by molecule, and is not being installed, as Ansible-core does not contain community modules.

INFO     centos-7 scenario test matrix: dependency, create, prepare
INFO     Performing prerun...
INFO     Guessed /home/vsts/work/1/s as project root directory
INFO     Added ANSIBLE_LIBRARY=./molecule:plugins/modules
INFO     Added ANSIBLE_COLLECTIONS_PATH=/home/vsts/.cache/ansible-lint/dc0145/collections
INFO     Added ANSIBLE_ROLES_PATH=~/.ansible/roles:/usr/share/ansible/roles:/etc/ansible/roles:roles
INFO     Running centos-7 > dependency
WARNING  Skipping, missing the requirements file.
WARNING  Skipping, missing the requirements file.
INFO     Running centos-7 > create
INFO     Sanity checks: 'docker'
[DEPRECATION WARNING]: Ansible will require Python 3.8 or newer on the
controller starting with Ansible 2.12. Current version: 3.6.14 (default, Jul  5
 2021, 20:52:02) [GCC 9.3.0]. This feature will be removed from ansible-core in
 version 2.12. Deprecation warnings can be disabled by setting
deprecation_warnings=False in ansible.cfg.
ERROR! couldn't resolve module/action 'docker_login'. This often indicates a misspelling, missing collection, or incorrect module path.

The error appears to be in '/opt/hostedtoolcache/Python/3.6.14/x64/lib/python3.6/site-packages/molecule_docker/playbooks/create.yml': line 11, column 7, but may
be elsewhere in the file depending on the exact syntax problem.

The offending line appears to be:

  tasks:
    - name: Log into a Docker registry
      ^ here
CRITICAL Ansible return code was 4, command was: ansible-playbook --inventory /home/vsts/.cache/molecule/s/centos-7/inventory --skip-tags molecule-notest,notest /opt/hostedtoolcache/Python/3.6.14/x64/lib/python3.6/site-packages/molecule_docker/playbooks/create.yml

Note: This was executed with Azure image ubuntu-20.04.

@rjeffman rjeffman added the bug label Aug 24, 2021
@tadeboro
Copy link
Contributor

This issue should be resolved by ansible-community/molecule-docker#77 and #3192

IIRC, Molecule with those changes has been already released, but we still need to make a docker driver release, so I am leaving this open until that happens.

@ssbarnea Are there any plans on releasing a new version of molecule docker driver?

@ssbarnea
Copy link
Member

molecule-docker 1.0.2 was released 5 days ago, closing. For bugs related to drivers please raise tickets with driver repositories instead of molecule itself.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants