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

feat(ec2): security group lookup via filters #30625

Merged
merged 23 commits into from
Aug 7, 2024

Conversation

jdukewich
Copy link
Contributor

@jdukewich jdukewich commented Jun 22, 2024

Issue # (if applicable)

Closes #30331.

Reason for this change

This will improve the security group lookup functionality for importing existing security groups into a CDK stack.

Description of changes

I added the ability to lookup existing security groups via more filters. Filters are supported by the DescribeSecurityGroups API, and using these filters can be immensely useful for looking up existing security groups, especially if your account or organization follows predictable rules regarding things like security group tags.

Description of how you validated changes

I added unit tests similar to the ones that test the normal lookup by ID or name.

Checklist


By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license

@github-actions github-actions bot added p2 beginning-contributor [Pilot] contributed between 0-2 PRs to the CDK labels Jun 22, 2024
@aws-cdk-automation aws-cdk-automation requested a review from a team June 22, 2024 18:18
Copy link
Collaborator

@aws-cdk-automation aws-cdk-automation left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The pull request linter has failed. See the aws-cdk-automation comment below for failure reasons. If you believe this pull request should receive an exemption, please comment and provide a justification.

A comment requesting an exemption should contain the text Exemption Request. Additionally, if clarification is needed add Clarification Request to a comment.

@aws-cdk-automation aws-cdk-automation added the pr/needs-cli-test-run This PR needs CLI tests run against it. label Jun 22, 2024
@jdukewich jdukewich changed the title feat(ec2): Security Group Lookup via Additional Filters feat(ec2): security group lookup via filters Jun 22, 2024
@github-actions github-actions bot added effort/small Small work item – less than a day of effort feature-request A feature should be added or improved. labels Jun 23, 2024
@jdukewich
Copy link
Contributor Author

Clarification Request

Does this feature need a new integration test? If so, I'm struggling to figure out how to write one for a lookup like this.

@aws-cdk-automation aws-cdk-automation added the pr/reviewer-clarification-requested The contributor has requested clarification on feedback, a failing build, or a failing PR Linter run label Jun 23, 2024
@jdukewich
Copy link
Contributor Author

Exemption Request

@aws-cdk-automation aws-cdk-automation added the pr-linter/exemption-requested The contributor has requested an exemption to the PR Linter feedback. label Jun 29, 2024
@aws-cdk-automation aws-cdk-automation added the pr/needs-community-review This PR needs a review from a Trusted Community Member or Core Team Member. label Jul 1, 2024
Copy link
Contributor

mergify bot commented Jul 17, 2024

update

❌ Mergify doesn't have permission to update

For security reasons, Mergify can't update this pull request. Try updating locally.
GitHub response: refusing to allow a GitHub App to create or update workflow .github/workflows/close-stale-prs.yml without workflows permission

Copy link
Contributor

@msambol msambol left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Thanks for adding the additional coverage in the integration test.

@aws-cdk-automation aws-cdk-automation added pr/needs-maintainer-review This PR needs a review from a Core Team Member and removed pr/needs-community-review This PR needs a review from a Trusted Community Member or Core Team Member. labels Aug 1, 2024
@aws-cdk-automation aws-cdk-automation removed the pr/needs-maintainer-review This PR needs a review from a Core Team Member label Aug 2, 2024
@xazhao
Copy link
Contributor

xazhao commented Aug 6, 2024

@Mergifyio update

Copy link
Contributor

mergify bot commented Aug 6, 2024

update

✅ Branch has been successfully updated

@xazhao
Copy link
Contributor

xazhao commented Aug 7, 2024

@Mergifyio update

Copy link
Contributor

mergify bot commented Aug 7, 2024

update

✅ Branch has been successfully updated

@xazhao
Copy link
Contributor

xazhao commented Aug 7, 2024

All tests passed. Adding the cli tested label.

@xazhao xazhao added the pr-linter/cli-integ-tested Assert that any CLI changes have been integ tested label Aug 7, 2024
@aws-cdk-automation aws-cdk-automation dismissed their stale review August 7, 2024 21:29

✅ Updated pull request passes all PRLinter validations. Dismissing previous PRLinter review.

@aws-cdk-automation aws-cdk-automation removed the pr/needs-cli-test-run This PR needs CLI tests run against it. label Aug 7, 2024
@aws-cdk-automation
Copy link
Collaborator

AWS CodeBuild CI Report

  • CodeBuild project: AutoBuildv2Project1C6BFA3F-wQm2hXv2jqQv
  • Commit ID: dd90497
  • Result: SUCCEEDED
  • Build Logs (available for 30 days)

Powered by github-codebuild-logs, available on the AWS Serverless Application Repository

Copy link
Contributor

mergify bot commented Aug 7, 2024

Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork).

@mergify mergify bot merged commit abc78bf into aws:main Aug 7, 2024
14 of 16 checks passed
Copy link

github-actions bot commented Aug 7, 2024

Comments on closed issues and PRs are hard for our team to see.
If you need help, please open a new issue that references this one.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 7, 2024
@TheRealAmazonKendra
Copy link
Contributor

We are now using an externally published version of cloud assembly schema. This needs to be reverted as it conflicts with that.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
beginning-contributor [Pilot] contributed between 0-2 PRs to the CDK effort/small Small work item – less than a day of effort feature-request A feature should be added or improved. p2 pr/reviewer-clarification-requested The contributor has requested clarification on feedback, a failing build, or a failing PR Linter run pr-linter/cli-integ-tested Assert that any CLI changes have been integ tested pr-linter/exemption-requested The contributor has requested an exemption to the PR Linter feedback.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

EC2: Security Groups lookup by Owner
6 participants