You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I just switched from molecule 2 to molecule 3.
I have a role with a local module:
role-a/library/conda.py
role-b has role-a as dependency and uses the conda module.
Running molecule lint should just work. It did with molecule 2.
Actual Behaviour
Running molecule lint fails because the conda module can't be found:
CRITICAL Couldn't parse task at /Users/.../role-b/tasks/main.yml:19 (couldn't resolve module/action 'conda'. This often indicates a misspelling, missing collection, or incorrect module path.)
In molecule 2, I noticed that ANSIBLE_ROLES_PATH was set when running molecule lint.
Setting it like that in my molecule.yml works but seems hacky:
lint: |
set -e
yamllint .
ANSIBLE_ROLES_PATH=${MOLECULE_EPHEMERAL_DIRECTORY}/roles ansible-lint
flake8
Could ANSIBLE_ROLES_PATH be set automatically when running molecule lint? Or do you have another suggestion?
This discussion was converted from issue #2804 on October 20, 2020 18:15.
Heading
Bold
Italic
Quote
Code
Link
Numbered list
Unordered list
Task list
Attach files
Mention
Reference
Menu
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Issue Type
Molecule and Ansible details
Molecule installation method (one of):
Ansible installation method (one of):
Detail any linters or test runners used:
Desired Behavior
I just switched from molecule 2 to molecule 3.
I have a role with a local module:
role-b has role-a as dependency and uses the
conda
module.Running
molecule lint
should just work. It did with molecule 2.Actual Behaviour
Running
molecule lint
fails because theconda
module can't be found:In molecule 2, I noticed that
ANSIBLE_ROLES_PATH
was set when runningmolecule lint
.Setting it like that in my
molecule.yml
works but seems hacky:Could
ANSIBLE_ROLES_PATH
be set automatically when runningmolecule lint
? Or do you have another suggestion?Beta Was this translation helpful? Give feedback.
All reactions