amazon.aws 6.0.0
Release Summary
This release brings some new plugins and features. Several bugfixes, breaking changes and deprecated features are also included. The amazon.aws collection has dropped support for botocore<1.25.0 and boto3<1.22.0. Support for Python 3.6 has also been dropped.
Minor Changes
- Add github actions to run unit and sanity tests.(#1393).
- AnsibleAWSModule - add support to the
clientandresourcemethods for overriding the default parameters (#1303). - CONTRIBUTING.md - refactors and adds to contributor documentation (#924)
- Refactor inventory plugins and add aws_rds inventory unit tests (#1218).
- Refactor module_utils/cloudfront_facts.py and add unit tests (#1265).
- The
blackcode formatter has been run across the collection to improve code consistency (#1465). - amazon.aws inventory plugins - additional refactorization of inventory plugin connection handling (#1271).
- amazon.aws lookup plugins -
aws_access_keyhas been renamed toaccess_keyfor consistency between modules and plugins,aws_access_keyremains as an alias. This change should have no observable effect for users outside the module/plugin documentation (#1225). - amazon.aws lookup plugins -
aws_profilehas been renamed toprofilefor consistency between modules and plugins,aws_profileremains as an alias. This change should have no observable effect for users outside the module/plugin documentation (#1225). - amazon.aws lookup plugins -
aws_secret_keyhas been renamed tosecret_keyfor consistency between modules and plugins,aws_secret_keyremains as an alias. This change should have no observable effect for users outside the module/plugin documentation (#1225). - amazon.aws lookup plugins -
aws_security_tokenhas been renamed tosession_tokenfor consistency between modules and plugins,aws_security_tokenremains as an alias. This change should have no observable effect for users outside the module/plugin documentation (#1225). - amazon.aws modules - bulk update of import statements following various refactors (#1310).
- autoscaling_group - minor linting fixes (#1181).
- aws_account_attribute - the
aws_account_attributelookup plugin has been refactored to useAWSLookupBaseas its base class (#1225). - aws_ec2 inventory - minor linting fixes (#1181).
- aws_secret - the
aws_secretlookup plugin has been refactored to useAWSLookupBaseas its base class (#1225). - aws_secret - the
aws_secretlookup plugin has been renamedsecretsmanager_secret,aws_secretremains as an alias (#1225). - aws_ssm - the
aws_ssmlookup plugin has been refactored to useAWSLookupBaseas its base class (#1225). - aws_ssm - the
aws_ssmlookup plugin has been renamedssm_parameter,aws_ssmremains as an alias (#1225). - backup - Add logic for backup_selection* modules (#1530).
- bulk migration of
%and.format()to fstrings (#1483). - cloud module_utils - minor linting fixes (#1181).
- cloudtrail_info - minor linting fixes (#1181).
- cloudwatchlogs_log_group - minor linting fixes (#1181).
- docs_fragments -
amazon.aws.boto3fragment now pulls the botocore version requirements frommodule_utils.botocore(#1248). - docs_fragments - common parameters for modules and plugins have been synchronised and moved to
amazon.aws.common.modulesandamazon.aws.common.plugins(#1248). - docs_fragments - region parameters for modules and plugins have been synchronised and moved to
amazon.aws.region.modulesandamazon.aws.region.plugins(#1248). - ec2_ami - Extend the unit-test coverage of the module (#1159).
- ec2_ami - allow
ImageAvailablewaiter to retry when the image can't be found (#1321). - ec2_ami_info - Add unit-tests coverage (#1252).
- ec2_eip - minor linting fixes (#1181).
- ec2_eni_info - Add unit-tests coverage (#1236).
- ec2_instance - avoid changing
module.params(#1187). - ec2_instance - updated to avoid manipulating
module.params(#1337). - ec2_security_group - added rule options to argument specifications to improve handling of inputs (#1214).
- ec2_security_group - refacter
get_target_from_rule()(#1221). - ec2_security_group - refactor rule expansion and add unit tests (#1261).
- ec2_snapshot - Reenable the integration tests (#1235).
- ec2_snapshot_info - Add unit-tests coverage (#1211).
- ec2_vpc_route_table - add support for Carrier Gateway entry (#926).
- ec2_vpc_subnet - retry fetching subnet details after creation if the first attempt fails (#1526).
- inventory aws ec2 - add parameter
use_ssm_inventoryallowing to query ssm inventory information for configured EC2 instances and populate hostvars (#704). - inventory plugins - refactor cache handling (#1285).
- inventory plugins - refactor file verification handling (#1285).
- inventory_aws_ec2 integration tests - replace local module
test_get_ssm_inventorybycommunity.aws.ssm_inventory_info(#1416). - kms_key_info - minor linting fixes (#1181).
- lambda - minor linting fixes (#1181).
- lambda - use common
get_aws_account_infohelper rather than reimplementing (#1181). - lambda_alias - refactored to avoid passing around the complex
moduleresource (#1336). - lambda_alias - updated to avoid manipulating
module.params(#1336). - lambda_execute - minor linting fixes (#1181).
- lambda_info - updated to avoid manipulating
module.params(#1336). - lambda_layer_info - add support for parameter version_number to retrieve detailed information for a specific layer version (#1293).
- module_utils - move RetryingBotoClientWrapper into module_utils.retries for reuse with other plugin types (#1230).
- module_utils - move exceptions into dedicated python module (#1246).
- module_utils - refacter botocore version validation into module_utils.botocore for future reuse (#1227).
- module_utils.acm - Refactor ACMServiceManager class and add unit tests (#1273).
- module_utils.botocore - Add Ansible AWS User-Agent identification (#1306).
- module_utils.botocore - refactorization of
get_aws_region,get_aws_connection_infoso that the code can be reused by non-module plugins (#1231). - module_utils.policy - minor refacter of code to reduce complexity and improve test coverage (#1136).
- module_utils.s3 - Refactor get_s3_connection into a module_utils for S3 modules and expand module_utils.s3 unit tests (#1139).
- module_utils/botocore - added support to
_boto3_connfor passing dictionaries of configuration (#1307). - plugin_utils - Added
AWSConnectionBaseto support refactoring connection plugins (#1340). - rds - AWS is phasing out aurora1. Integration tests use aurora2 (aurora-mysql) by default (#1233).
- rds_cluster - Split up the functional tests in smaller targets (#1175).
- rds_cluster_snapshot - minor linting fixes (#1181).
- rds_instance - minor linting fixes (#1181).
- rds_instance_info - Add unit-tests coverage (#1132).
- rds_instance_snapshot - minor linting fixes (#1181).
- rds_param_group - drop Python2 import fallbacks (#1513).
- route53_health_check - Drop deprecation warning (ansible-collections/community.aws#1335).
- route53_health_check - minor fix for returning health check info while updating a Route53 health check (#1200).
- route53_health_check - minor linting fixes (#1181).
- route53_info - drop unused imports (#1462).
- s3_bucket - add support for S3 dualstack endpoint (#1305).
- s3_bucket - handle missing read permissions more gracefully when possible (#1406).
- s3_bucket - refactor S3 connection code (#1305).
- s3_object - refactor S3 connection code (#1305).
- s3_object - refactor main to reduce complexity (#1193).
- s3_object_info - minor linting fixes (#1181).
- s3_object_info - refactor S3 connection code (#1305).
Breaking Changes / Porting Guide
- The amazon.aws collection has dropped support for
botocore<1.25.0andboto3<1.22.0. Most modules will continue to work with older versions of the AWS SDK, however compatibility with older versions of the SDK is not guaranteed and will not be tested. When using older versions of the SDK a warning will be emitted by Ansible (#1342). - amazon.aws - compatibility code for Python < 3.6 has been removed (#1257).
- ec2_eip - the previously deprecated
instance_idalias for thedevice_idparameter has been removed. Please use thedevice_idparameter name instead (#1176). - ec2_instance - the default value for
instance_typehas been removed. At least one ofinstance_typeorlaunch_templatemust be specified when launching new instances (#1315). - ec2_vpc_dhcp_options - the
new_optionsreturn value has been deprecated after being renamed todhcp_config. Please use thedhcp_configordhcp_optionsreturn values (#1327). - ec2_vpc_endpoint - the
policy_fileparameter has been removed. I(policy) with a file lookup can be used instead (#1178). - ec2_vpc_net - the
classic_link_enabledreturn value has been removed. Support for EC2 Classic networking was dropped by AWS (#1374). - ec2_vpc_net_info - the
classic_link_dns_statusreturn value has been removed. Support for EC2 Classic networking was dropped by AWS (#1374). - ec2_vpc_net_info - the
classic_link_enabledreturn value has been removed. Support for EC2 Classic networking was dropped by AWS (#1374). - module_utils.cloud - the previously deprecated
CloudRetry.backoffhas been removed. Please useCloudRetry.exponential_backofforCloudRetry.jittered_backoffinstead (#1110).
Deprecated Features
- amazon.aws collection - due to the AWS SDKs Python support policies (https://aws.amazon.com/blogs/developer/python-support-policy-updates-for-aws-sdks-and-tools/) support for Python less than 3.8 by this collection is expected to be removed in a release after 2024-12-01 (#1342).
- amazon.aws collection - due to the AWS SDKs announcing the end of support for Python less than 3.7 (https://aws.amazon.com/blogs/developer/python-support-policy-updates-for-aws-sdks-and-tools/) support for Python less than 3.7 by this collection has been deprecated and will be removed in release 7.0.0. (#1342).
- amazon.aws lookup plugins - the
boto3_profilealias for theprofileoption has been deprecated, please useprofileinstead (#1225). - docs_fragments -
amazon.aws.aws_credentialsdocs fragment has been deprecated please useamazon.aws.common.pluginsinstead (#1248). - docs_fragments -
amazon.aws.aws_regiondocs fragment has been deprecated please useamazon.aws.region.pluginsinstead (#1248). - docs_fragments -
amazon.aws.awsdocs fragment has been deprecated please useamazon.aws.common.modulesinstead (#1248). - docs_fragments -
amazon.aws.ec2docs fragment has been deprecated please useamazon.aws.region.modulesinstead (#1248). - module_utils.policy -
ansible_collections.amazon.aws.module_utils.policy.sort_json_policy_dicthas been deprecated consider usingansible_collections.amazon.aws.module_utils.poilcies.compare_policiesinstead (#1136). - s3_object - Support for passing
dualstackandendpoint_urlat the same time has been deprecated, thedualstackparameter is ignored whenendpoint_urlis passed. Support will be removed in a release after 2024-12-01 (#1305). - s3_object - Support for passing values of
overwriteother thanalways,never,differentor lastlasthas been deprecated. Boolean values should be replaced by the stringsalwaysorneverSupport will be removed in a release after 2024-12-01 (#1305). - s3_object_info - Support for passing
dualstackandendpoint_urlat the same time has been deprecated, thedualstackparameter is ignored whenendpoint_urlis passed. Support will be removed in a release after 2024-12-01 (#1305).
Removed Features (previously deprecated)
- ec2_vpc_endpoint_info - support for the
queryparameter was removed. Theamazon.aws.ec2_vpc_endpoint_infomodule now only queries for endpoints. Services can be queried using theamazon.aws.ec2_vpc_endpoint_service_infomodule (#1308). - s3_object - support for creating and deleting buckets using the
s3_objectmodule has been removed. S3 buckets can be created and deleted using theamazon.aws.s3_bucketmodule (#1112).
Bugfixes
- ec2_security_group - file included unreachable code. Fix now removes unreachable code by removing an inapproproate logic (#1348).
- ec2_vpc_dhcp_option - retry
describe_dhcp_optionsafter creation whenInvalidDhcpOptionID.NotFoundis raised (#1320). - lambda_execute - Fix waiter error when function_arn is passed instead of name(#1268).
- module_utils - fixes
TypeError: deciding_wrapper() got multiple values for argument 'aws_retry'when passing positional arguments to functions wrapped by AnsibleAWSModule.client (#1230). - rds_param_group - added a check to fail the task while modifying/updating rds_param_group if trying to change DB parameter group family. (#1169).
- route53_health_check - Fix
Nametag key removal idempotentcy issue when creating health_check withuse_unique_namesandtagsset (#1253). - s3_bucket - Handle setting of permissions while acl is disabled.(#1168).
New Plugins
Lookup
- aws_collection_constants - expose various collection related constants
New Modules
- backup_plan - Manage AWS Backup Plans
- backup_plan_info - Describe AWS Backup Plans
- backup_restore_job_info - List information about backup restore jobs
- backup_selection - Create, delete and modify AWS Backup selection
- backup_selection_info - Describe AWS Backup Selections
- backup_tag - Manage tags on backup plan, backup vault, recovery point
- backup_tag_info - List tags on AWS Backup resources
- backup_vault - Manage AWS Backup Vaults
- backup_vault_info - Describe AWS Backup Vaults