-
Notifications
You must be signed in to change notification settings - Fork 60
Add support for adoption of existing Flow Logs and Security Groups #160
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
Conversation
|
Hi @pcolazurdo. Thanks for your PR. I'm waiting for a aws-controllers-k8s member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: pcolazurdo The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
|
/ok-to-test |
a-hilaly
left a comment
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.
Neat, thank you @pcolazurdo ! i left few comments in-line
Also can we add some e2e tests to validate that those adoptions are working and won't break in the future?
templates/hooks/security_group/post_set_resource_identifiers.go.tpl
Outdated
Show resolved
Hide resolved
|
Tried to find an example of an adopted check to use as a baseline, but couldn't find one. For these two resources adoption, we should create a new Security Group manually, and create a new VPC with flow log enabled. How should I proceed with this? I don't want to stand up new resources that will be hard to tear down after, and I don't fully understand the e2e workflow. |
Instead of creating everything manually, you can use ACK it self to provision those resources... once provisioned you can annotate those resources with a delete-retain-policy and try to adopt right after. https://aws-controllers-k8s.github.io/community/docs/user-docs/deletion-policy/ |
|
@pcolazurdo Did you test those changes locally? happy to merge if you say it worked for locally. We need a global plan to add resource adoption tests.. |
|
I've done some more testing and there is an issue with the Security Group adoption that I haven't been able to solve as this seems to be an issue with this particular API and how the runtime manager required fields. I'll also create a different PR for the VPC Flow Logs piece. In this case, the AWS API doesn't allow mutation so there is no side effect if the user makes a mistake when defining the values of the additionalKeys. |
Issue #, if available: aws-controllers-k8s/community#1946
Description of changes:
This proposed fix add support for additionalKeys needed to support adoption of Security Groups and FlowLogs as requested on the issue linked above.
The following adoption instructions will now work:
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.