Fix: skip unopted-in AWS regions in aws_ec2 inventory plugin#2669
Fix: skip unopted-in AWS regions in aws_ec2 inventory plugin#2669armin-x86 wants to merge 3 commits intoansible-collections:mainfrom
Conversation
Signed-off-by: armin-x86 <arminteymuri@gmail.com>
Signed-off-by: armin-x86 <arminteymuri@gmail.com>
|
Build failed. ✔️ ansible-galaxy-importer SUCCESS in 5m 56s |
my patch passes all linting and packaging tests. The integration-amazon.aws-1 job failed due to a symlink creation error Could you please help re-run or advise if this is an infra issue? |
|
any chance to have it approved? |
Summary
This pull request improves the robustness of the
amazon.aws.aws_ec2dynamic inventory plugin by gracefully skipping AWS regions that are not opted-in or enabled in the account.Currently, if a user includes disabled/not enabled regions on their aws account like
ap-east-1orme-south-1in theregions:list of their inventory config, the plugin throws a misleadingAuthFailureerror, even though the credentials are valid.This PR introduces a targeted
ClientErrorhandler that:AuthFailureBefore
and no inventory was rendered because having not activated/disabled regions in the regions list.
After
Changelog
CI is failing due to unrelated warnings in docsite/CHANGELOG.rst (missing references to result and vpc_peering_connections). This appears unrelated to this PR, as it doesn't touch documentation or changelogs involving those terms.