1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

add root_device_type filter. (#31911)

* add root_device_type filter.

This module is due for a refactor, but I'm piling on.

* add version added
This commit is contained in:
Ted Timmons 2017-10-19 11:59:15 -07:00 committed by ansibot
parent 2ffe3c42bb
commit d2e01477eb

View file

@ -143,6 +143,12 @@ options:
- Virtualization type to match (e.g. hvm). - Virtualization type to match (e.g. hvm).
default: null default: null
required: false required: false
root_device_type:
description:
- Root device type to match (e.g. ebs, instance-store).
default: null
required: false
version_added: "2.5"
no_result_action: no_result_action:
description: description:
- What to do when no results are found. - What to do when no results are found.
@ -354,6 +360,7 @@ def main():
owner = module.params.get('owner') owner = module.params.get('owner')
platform = module.params.get('platform') platform = module.params.get('platform')
product_code = module.params.get('product_code') product_code = module.params.get('product_code')
root_device_type = module.params.get('root_device_type')
sort = module.params.get('sort') sort = module.params.get('sort')
sort_tag = module.params.get('sort_tag') sort_tag = module.params.get('sort_tag')
sort_order = module.params.get('sort_order') sort_order = module.params.get('sort_order')
@ -382,6 +389,8 @@ def main():
filter['platform'] = platform filter['platform'] = platform
if product_code: if product_code:
filter['product-code'] = product_code filter['product-code'] = product_code
if root_device_type:
filter['root_device_type'] = root_device_type
if virtualization_type: if virtualization_type:
filter['virtualization_type'] = virtualization_type filter['virtualization_type'] = virtualization_type