From f8fa772a5597a7699a39cae55989952b98732476 Mon Sep 17 00:00:00 2001 From: Sean Summers Date: Fri, 30 Dec 2016 09:28:13 -0600 Subject: [PATCH] ec2_ami_find: set is_public to 'true' or 'false' (#19250) * set is_public 'true' or 'false' Despite being a boolean property, https://github.com/melta/boto/blob/master/boto/ec2/image.py:63 sets is_public = True only if the argument is passed in as the string 'true'. Likewise for False/'false'. This is a workaround for that bug in boto2, to allow the documented parameter to work with valid yaml values. fixes #5600 * only set is_public if true --- lib/ansible/modules/cloud/amazon/ec2_ami_find.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/ansible/modules/cloud/amazon/ec2_ami_find.py b/lib/ansible/modules/cloud/amazon/ec2_ami_find.py index c6b986bdd80..f7a529c7071 100644 --- a/lib/ansible/modules/cloud/amazon/ec2_ami_find.py +++ b/lib/ansible/modules/cloud/amazon/ec2_ami_find.py @@ -357,7 +357,7 @@ def main(): if hypervisor: filter['hypervisor'] = hypervisor if is_public: - filter['is_public'] = is_public + filter['is_public'] = 'true' if name: filter['name'] = name if platform: