Skip to content

Fix molecule test failing due to Ansible not being installed #393

Description

@geerlingguy

When I run ansible-lint via Molecule in the molecule example in CI, it fails because Ansible is not installed. The latest versions of ansible-lint no longer strictly depend on Ansible, so it is not installed by default. Need to explicitly install it.

Molecule default > lint
  COMMAND: set -e
  yamllint .
  ansible-lint
  
  Unable to find a working copy of ansible executable. CompletedProcess(args=['ansible', '--version'], returncode=1, stdout='', stderr='Traceback (most recent call last):\n  File "/usr/bin/ansible", line 34, in <module>\n    from ansible import context\nModuleNotFoundError: No module named \'ansible\'\n')
  CRITICAL Lint failed with error code 4
WARNING  An error occurred during the test sequence action: 'lint'. Cleaning up.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions