ansible-community / molecule-libvirt

Molecule LibVirt Provider
https://github.com/ansible-community/molecule-libvirt/issues/13#issuecomment-1372615418
MIT License
35 stars 19 forks source link

disk_size and memory_size ignored in molecule.yml #35

Open lmelwyn opened 2 years ago

lmelwyn commented 2 years ago

Hi,

At first, thank you for providing this plugin, and secondly, I noticed that "item." is missing a couple of places, so that some definitions in molecule.yml are ignored when creating vms.

grep -ir "default(" | grep -v item
molecule_libvirt/playbooks/create.yml:        {{ disk_size | default(default_disk_size ) }}"
molecule_libvirt/playbooks/templates/vm/vm.xml.j2:  <memory unit='GiB'>{{ memory_size | default(default_memory_size) }}</memory>
molecule_libvirt/playbooks/templates/vm/vm.xml.j2:  <currentMemory unit='GiB'>{{ memory_size | default(default_memory_size) }}</currentMemory>
molecule_libvirt/playbooks/templates/vm/vm.xml.j2:  <vcpu placement='static'>{{ vcpu | default(default_vcpu) }}</vcpu>

Also, would you consider adding (or accepting) a couple of miscellaneous start and stop functions corresponding to virsh start and shutdown.

Regards, Lars Melwyn

goldyfruit commented 2 years ago

@lmelwyn Thanks for reporting this, do you think you could write a pull request for this issue? Once done I'll review it.

About your next question, could you please open a new issue with a detailed description of what you are trying to achieve?

Thanks!