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

Deprecate ec2_ami_find #32501

Merged
merged 1 commit into from
Nov 9, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ Ansible Changes By Release
* The ``with_<lookup>`` loops are deprecated in favor of the new ``loop`` keyword

#### Deprecated Modules (to be removed in 2.9):
* ec2_ami_find

#### Removed Modules (previously deprecated):
* accelerate
Expand Down Expand Up @@ -42,6 +43,7 @@ Ansible Changes By Release

* aws_ssm_parameter_store
* digital_ocean_sshkey_facts
* ec2_ami_facts

#### Windows

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@


ANSIBLE_METADATA = {'metadata_version': '1.1',
'status': ['preview'],
'status': ['deprecated'],
'supported_by': 'community'}


Expand All @@ -16,6 +16,7 @@
module: ec2_ami_find
version_added: '2.0'
short_description: Searches for AMIs to obtain the AMI ID and other information
deprecated: Deprecated in 2.5. Use M(ec2_ami_facts) instead.
description:
- Returns list of matching AMIs with AMI ID, along with other useful information
- Can search AMIs with different owners
Expand Down Expand Up @@ -348,6 +349,8 @@ def main():
supports_check_mode=True,
)

module.deprecate("The 'ec2_ami_find' module has been deprecated. Use 'ec2_ami_facts' instead.", version=2.9)

if not HAS_BOTO:
module.fail_json(msg='boto required for this module, install via pip or your package manager')

Expand Down
2 changes: 1 addition & 1 deletion test/sanity/pep8/legacy-files.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
lib/ansible/modules/cloud/amazon/_ec2_ami_find.py
lib/ansible/modules/cloud/amazon/_ec2_ami_search.py
lib/ansible/modules/cloud/amazon/_ec2_remote_facts.py
lib/ansible/modules/cloud/amazon/_ec2_vpc.py
Expand All @@ -7,7 +8,6 @@ lib/ansible/modules/cloud/amazon/cloudformation.py
lib/ansible/modules/cloud/amazon/cloudfront_facts.py
lib/ansible/modules/cloud/amazon/dynamodb_table.py
lib/ansible/modules/cloud/amazon/ec2_ami_copy.py
lib/ansible/modules/cloud/amazon/ec2_ami_find.py
lib/ansible/modules/cloud/amazon/ec2_elb.py
lib/ansible/modules/cloud/amazon/ec2_elb_lb.py
lib/ansible/modules/cloud/amazon/ec2_eni_facts.py
Expand Down