Container drivers are not working
mrbrandao opened this issue · 0 comments
mrbrandao commented
Prerequisites
- This was not already reported in the past (duplicate check)
- It does reproduce it with code from main branch (latest unreleased version)
- I include a minimal example for reproducing the bug
- The bug is not trivial, as for those a direct pull-request is preferred
- Running
pip check
does not report any conflicts - I was able to reproduce the issue on a different machine
- The issue is not specific to any driver other than 'default' one
Environment
molecule 6.0.3 using python 3.11
ansible:2.16.3
default:6.0.3 from molecule
podman:2.0.3 from molecule_podman requiring collections: containers.podman>=1.7.0 ansible.posix>=1.3.0
What happened
- When using
molecule init scenario -d podman
the driver is not declared in themolecule.yml
- When running the
molecule create
it will create using thedefault
driver instead, of the one specified ininit
command. - After manually adding the driver in
molecule.yml
, thecreate
anddestroy
plays, will still not use the declared driver, skipping all tasks. when removing the defaultcreate.yml
anddestroy.yml
, then it will behavior as intended.
What I expect to happen?
- The command
molecule init scenario -d podman
to create the propermolecule.yml
with the driver declared - The command
molecule create
to create the container using the specified driver - The command
molecule destroy
to destroy the running container created.
Reproducing example
python3.11 -m venv .venv
source .venv/bin/activate
pip install ansible-core molecule molecule-podman
ansible-galaxy collection init foo.example
cd foo/example/roles
ansible-galaxy role init bar
cd bar
molecule init scenario -d podman
molecule create
molecule destroy