--env-file Issue

143 views
Skip to first unread message

Fauzan

unread,
May 25, 2020, 10:38:24 PM5/25/20
to molecule-users
Hi there,

I have concern for --env-file flags when running Ansible Molecule.

When running:

molecule
--env-file env.yml converge


It turns out that we got an error like this:

ERROR! an error occurred while trying to read the file '/Users/irwan.shofwan/.ansible/roles/ipsec-user-vpn/molecule/default': [Errno 21] Is a directory: b'/Users/<Users>/.ansible/roles/<ansible-role-name>/molecule/default'
ERROR:

When we are running Molecule with --debug flag, the MOLECULE_ENV_FILE is set properly to our DIR path.

MOLECULE_ENV_FILE=/Users/irwan.shofwan/.ansible/roles/ipsec-user-vpn/.env.yml

Currently, we are looking from this docs https://molecule.readthedocs.io/en/latest/usage.html on how to use the --env-file flag. 

We would like to know how to use this flag properly. Is this issue related to https://github.com/ansible-community/molecule/issues/1841? Thanks

Mohit Kumar Sharma

unread,
May 28, 2020, 9:10:11 AM5/28/20
to molecule-users
looks like you dont have default scenario 

Irwan Shofwan

unread,
Jun 20, 2020, 8:11:35 AM6/20/20
to molecule-users
Not sure about that because when you use molecule role init it will be generated default scenario afaik, CMIIW
Reply all
Reply to author
Forward
0 new messages