ec2_ami_facts: return images in a consistent order (#40679)
* ec2_ami_facts: return images in a consistent order
This commit is contained in:
parent
496d10f7a8
commit
9d30434b6c
1 changed files with 1 additions and 0 deletions
|
@ -234,6 +234,7 @@ def list_ec2_images(ec2_client, module):
|
||||||
# describing launch permissions of images owned by others is not permitted, but shouldn't cause failures
|
# describing launch permissions of images owned by others is not permitted, but shouldn't cause failures
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
images.sort(key=lambda e: e.get('creation_date', '')) # it may be possible that creation_date does not always exist
|
||||||
module.exit_json(images=images)
|
module.exit_json(images=images)
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue