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

Make sure droplet deletion works even when idempotency is achieved using 'name' and 'unique_name' rather than 'id' #6104

Merged
merged 1 commit into from Mar 11, 2014

Conversation

gianlucaborello
Copy link
Contributor

So this fixes a bug that makes it impossible to delete a droplet that is specified with just a combination of name and unique_names (for idempotency).

In particular, without the fix, this code:

digital_ocean:
  image_id=1646467
  name=mydroplet
  ssh_key_ids=54036
  size_id=63
  region_id=4
  state=absent
  unique_name=yes

will always fail with:

TASK: [deploy droplets] *******************************************************
failed: [127.0.0.1] => (item=mydroplet) => {"failed": true, "item": "mydroplet"}
msg: Unable to load id

FATAL: all hosts have already failed -- aborting

because the module will fail, not finding 'id' (even though, according to the manual and to what I need to do, seems like a completely legit case)

…ing 'name' and 'unique_name' rather than 'id'
mpdehaan added a commit that referenced this pull request Mar 11, 2014
Make sure droplet deletion works even when idempotency is achieved using 'name' and 'unique_name' rather than 'id'
@mpdehaan mpdehaan merged commit 003a405 into ansible:devel Mar 11, 2014
@mpdehaan
Copy link
Contributor

Merged, thanks!

@ansibot ansibot added bug This issue/PR relates to a bug. and removed bugfix_pull_request labels Mar 5, 2018
@ansible ansible locked and limited conversation to collaborators Apr 24, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug This issue/PR relates to a bug. cloud digital_ocean
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants