"molecule.yml as only config required" support for plugins (molecule-hetznercloud)
See original GitHub issueIssue Type
- Feature request
Molecule and Ansible details
- Latest
Molecule installation method (one of):
- pip
Ansible installation method (one of):
- pip
Desired Behavior
I’m migrating a lot of roles to Molecule 3.0 and it’s quite a piece of work. That’s fine and I’m glad to be able to do it. However, it got me thinking, it would be excellent if I only had to migrate my molecule.yml
and not the prepare/create/destroy etc. (there were changes in the plugin implementation).
I have no custom changes to the create/destroy/prepare yaml files whatsoever. I feel like I don’t need to see them in the molecule/default/
folder. If they weren’t there, then I really wouldn’t notice and I would have a lot less work to do.
This would upstream maintenance work into the plugin (for create/prepare/destroy/etc.) and make migration much easier (allowing more flexibility in the molecule.yml definitions because you only have to change one file now).
So, my request is, can we make it such that if you have no create.yml
in your molecule/default
folder, then molecule looks at your driver plugin and then does a lookup into the plugin directory path to run the default create/prepare/destroy/etc. You can always override.
Issue Analytics
- State:
- Created 3 years ago
- Comments:6 (6 by maintainers)
I do not remember how I implemented it, you need to dig a bit. Still, I would fully support an implementation that makes this default for all plugins. Maybe they could override it in the future, but I see no harm to assume it default.
I think there are few plugins that do not use playbooks for create/destroy, probably these are more problematic as you still want to call their internal implementation.
Ok, I just had to add a “playbooks” dir to my plugin implementation and bundle there.