-
Notifications
You must be signed in to change notification settings - Fork 341
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
ec2_security_group - Move validation for rules into the arg_spec #1214
ec2_security_group - Move validation for rules into the arg_spec #1214
Conversation
Docs Build 📝Thank you for contribution!✨ This PR has been merged and your docs changes will be incorporated when they are next published. |
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as resolved.
This comment was marked as resolved.
8b57ac0
to
6e927a2
Compare
@@ -1170,6 +1192,7 @@ def get_final_rules(client, module, security_group_rules, specified_rules, purge | |||
rule[source_type] = [rule[source_type]] | |||
format_rule[rule_key] = [{source_type: target} for target in rule[source_type]] | |||
if rule.get('group_id') or rule.get('group_name'): | |||
# XXX bug - doesn't cope with a list of ids/names |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Existing bug - #1217 want to split proper solution as the diff code is gnarly
6e927a2
to
40037c3
Compare
Merge Failed. This change or one of its cross-repo dependencies was unable to be automatically merged with the current state of its repository. Please rebase the change and upload a new patchset. |
regate |
Backport to stable-5: 💔 cherry-picking failed — conflicts found❌ Failed to cleanly apply 896fe7a on top of patchback/backports/stable-5/896fe7aca231860ee3a573b11cb772f86836c4ea/pr-1214 Backporting merged PR #1214 into main
🤖 @patchback |
ec2_security_group - refacter get_target_from_rule() SUMMARY refacter get_target_from_rule to bring down the complexity score Builds on top of #1214 ISSUE TYPE Feature Pull Request COMPONENT NAME ec2_security_group ADDITIONAL INFORMATION Reviewed-by: Alina Buzachis <None>
Fix ec2_metadata_facts integration test SUMMARY With #1214 security_group now validates the rules its passed, requiring a "source" be passed (SG/CIDR). Previously it just dropped the rule on the floor. This has however broken the ec2_metadata_facts integration test ISSUE TYPE Bugfix Pull Request COMPONENT NAME ec2_metadata_facts ADDITIONAL INFORMATION Reviewed-by: Alina Buzachis <None>
SUMMARY
The bulk of the current rule validation can be better handled by arg_spec parameter validation.
ISSUE TYPE
COMPONENT NAME
ec2_security_group
ADDITIONAL INFORMATION