Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Inventory Source module dosen't delete hosts and groups. #15366

Open
4 of 9 tasks
valkiriaaquatica opened this issue Jul 16, 2024 · 0 comments
Open
4 of 9 tasks

Inventory Source module dosen't delete hosts and groups. #15366

valkiriaaquatica opened this issue Jul 16, 2024 · 0 comments
Labels
community component:awx_collection issues related to the collection for controlling AWX help wanted type:enhancement

Comments

@valkiriaaquatica
Copy link

Please confirm the following

  • I agree to follow this project's code of conduct.
  • I have checked the current issues for duplicates.
  • I understand that AWX is open source software provided for free and that I might not receive a timely response.

Feature type

Enhancement to Existing Feature

Feature Summary

Hi,
when using the module in AAP and AWX: inventory_source https://docs.ansible.com/ansible/latest/collections/awx/awx/inventory_source_module.html for deleting sources from inventory, when a source is deleted, the hosts and groups still exist and they are not deleted while when you delete them from IU they are deleted.

Select the relevant components

  • UI
  • API
  • Docs
  • Collection
  • CLI
  • Other

Steps to reproduce

  1. Have a AWX or AAP working.
  2. Create an inventoty and add a source
  3. Sync the source to get hosts
  4. Delete that source with the module
    • name: Dlete inventory source from AAP or AWX
      awx.awx.inventory_source:
      controller_host: "https:/domain.com"
      controller_username: "user"
      controller_password: "123456"
      name: "0987654321"
      inventory: "AWS"
      state: absent
      This will delete the source but not the hosts... there should be a nw argument for host_deletion: bool and group_deletion: bool.

Current results

The source from the invntory id well deleted but not the associated hosts and groups that has that source.

Sugested feature result

I would think of add two new arguments host_deletion: bool and group_deletation: true that if those and state: absent are passed in the module it deletes the hosts and groups associated with the source.

Additional information

No response

@github-actions github-actions bot added component:awx_collection issues related to the collection for controlling AWX needs_triage type:enhancement community labels Jul 16, 2024
@valkiriaaquatica valkiriaaquatica changed the title Inventory Source module dosent' delete hosts and groups. Inventory Source module dosen't delete hosts and groups. Jul 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
community component:awx_collection issues related to the collection for controlling AWX help wanted type:enhancement
Projects
None yet
Development

No branches or pull requests

2 participants