Hi,
Machines that are powered off but match the tags in the EC2 module are not recognised by exact_count. Consider: - A script provisioning an instance with exact_count of 1 and associated tags is run. - When run a second time, as expected the script does not provision another instance. - However if the machine is stopped, and then the script is run again, another instance is provisioned. The current implementation of exact_count assumes having a stopped machine should behave as if it does not exist, and will therefore provision another. I would prefer to see machine state be considered as part of the exact_count match. Use of the state tag as part of the exact_count criteria seems to be a good option. Current Ansible does not allow this — a *parameters are mutually exclusive: ['exact_count', 'state'])* exception is thrown. Is there something I am missing, or perhaps another way to ensure that the machine is not reprovisioned when stopped. Happy to attempt to modify the module and submit a PR, but wanted your thoughts first. Thanks so much, Steve -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/f1742af8-0029-44e8-b14b-ea59ecaa5f69%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
