ansible-community / molecule-plugins

Collection on molecule plugins
MIT License
109 stars 73 forks source link

Plugin openstack #157

Closed genaumann closed 9 months ago

genaumann commented 1 year ago

This PR contains the openstack driver for molecule.

Local tests were successfull.

genaumann commented 1 year ago

@konstruktoid volume support added.

Could you help to fix the "tox / lint" job?

konstruktoid commented 1 year ago

The lint job will be fixed with https://github.com/ansible-community/molecule-plugins/pull/159, but I don't have permissions to add or remove tags.

konstruktoid commented 1 year ago

volume support added.

Awesome, will test as soon as possible

genaumann commented 1 year ago

@konstruktoid I refactored the volume creation.

konstruktoid commented 1 year ago

awesome, i'll have a look as soon as possible

konstruktoid commented 1 year ago

WFM using:

dependency:
  name: galaxy
  enabled: true
driver:
  name: openstack
provisioner:
  name: ansible
  playbooks:
    converge: ../default/converge.yml
    verify: ../default/verify.yml
  log: true
platforms:
  - name: REDACTED
    image: REDACTED
    network:
      name: REDACTED
      create: false
    volume:
      size: 10
    user: ubuntu
    flavor: REDACTED
    env:
      http_proxy: ${http_proxy}
      https_proxy: ${https_proxy}
      no_proxy: ${no_proxy}
verifier:
  name: ansible
scenario:
[...]
konstruktoid commented 1 year ago

https://github.com/ansible-community/molecule/issues/3919 will probably impact this

genaumann commented 1 year ago

@konstruktoid what is the current status? Do you need anything else so that the PR can be merged?

konstruktoid commented 1 year ago

Just that any conflicts and lints need to be fixed, and then another reviewer with merge permissions needs to give a thumbs up.

genaumann commented 1 year ago

The lint job will be fixed with #159, but I don't have permissions to add or remove tags.

I thought the lint job is fixed with #159. Local linting was successfull. I will have a look at the merge conflict.

juanlufont commented 10 months ago

The lint job will be fixed with #159, but I don't have permissions to add or remove tags.

I thought the lint job is fixed with #159. Local linting was successfull. I will have a look at the merge conflict.

Hi!

I locally merged your OpenStack plugin code with the molecule-plugins upstream "main" branch to check the code against the latest lint configuration, I got only 2 errors:

yaml[octal-values]: Forbidden implicit octal value "0600"
test/roles/openstackplugin/molecule/default/create.yml:36

yaml[octal-values]: Forbidden implicit octal value "0600"
test/roles/openstackplugin/molecule/default/destroy.yml:23

After using quotes around those 0600 permission strings the code passed all the latest lint tests. I can create a PR against your fork, but the changes are so minimal that you may want to apply them directly to save some hassle.

EDIT: I have just realized those test files are auto-generated, it looks like you only have to add them to .ansible-lint-ignore, it already contains similar entries for the other plugins.