Skip to content

Commit

Permalink
Bulk migration to AnsibleAWSModule (ansible-collections#173)
Browse files Browse the repository at this point in the history
* Update comments to reference AnsibleAWSModule rather than AnsibleModule
* Bulk re-order imports and split onto one from import per-line.
* Add AnsibleAWSModule imports
* Migrate boto 2 based modules to AnsibleAWSModule
* Move boto3-only modules over to AnsibleAWSModule
* Remove extra ec2_argument_spec calls - not needed now we're using AnsibleAWSModule
* Remove most HAS_BOTO3 code, it's handled by AnsibleAWSModule
* Handle missing Boto 2 consistently  (HAS_BOTO)
* Remove AnsibleModule imports
* Changelog fragment

This commit was initially merged in https://github.com/ansible-collections/community.aws
See: ansible-collections/community.aws@818c6d2
  • Loading branch information
tremble authored and github-actions[bot] committed Oct 25, 2023
1 parent c0a67d3 commit e24183e
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions plugins/modules/ec2_ami_copy.py
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,8 @@
'''

from ansible_collections.amazon.aws.plugins.module_utils.core import AnsibleAWSModule
from ansible_collections.amazon.aws.plugins.module_utils.ec2 import camel_dict_to_snake_dict, ansible_dict_to_boto3_tag_list
from ansible_collections.amazon.aws.plugins.module_utils.ec2 import camel_dict_to_snake_dict
from ansible_collections.amazon.aws.plugins.module_utils.ec2 import ansible_dict_to_boto3_tag_list
from ansible.module_utils._text import to_native

try:
Expand All @@ -147,7 +148,7 @@ def copy_image(module, ec2):
"""
Copies an AMI
module : AnsibleModule object
module : AnsibleAWSModule object
ec2: ec2 connection object
"""

Expand Down

0 comments on commit e24183e

Please sign in to comment.