Skip to content

Commit

Permalink
Fix issue with overwrite_existing on ah_collection module (ansible#385)
Browse files Browse the repository at this point in the history
Co-authored-by: David Danielsson <[email protected]>
  • Loading branch information
Tompage1994 and djdanielsson authored Apr 17, 2024
1 parent d05e94e commit 2c54eea
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
4 changes: 4 additions & 0 deletions changelogs/fragments/collection_overwrite_existing.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
---
bugfixes:
- Fixes issue with overwriting existing collection where timing didn't work correctly
...
1 change: 1 addition & 0 deletions plugins/modules/ah_collection.py
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,7 @@ def main():
# Delete collection
module.json_output["task"] = module.delete_endpoint(existing_item["json"]["href"])["json"]["task"]
module.json_output["deleted"] = True
module.wait_for_complete(module.json_output["task"])
# Upload new collection
module.upload(path, "artifacts/collections", wait, item_type="collections")
module.json_output["changed"] = True
Expand Down

0 comments on commit 2c54eea

Please sign in to comment.