-
Notifications
You must be signed in to change notification settings - Fork 372
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(iam): Add observe and update of user permissions boundary #1735
feat(iam): Add observe and update of user permissions boundary #1735
Conversation
Signed-off-by: Ben McDonie <[email protected]>
Signed-off-by: Ben McDonie <[email protected]>
Signed-off-by: Ben McDonie <[email protected]>
I am working on updating this to support IAM Role as well (to fully close #1080 ). I'd appreciate any feedback/testing from the community as I do not use Roles in my setup. I will update unit tests and then test as much as I can. |
Signed-off-by: Ben McDonie <[email protected]>
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.
Thank you for your contribution @zonybob.
This looks pretty close to merge for me. Can you fix the issues I remarked?
…-permissionsboundary
move error.Wrap calls Signed-off-by: Ben McDonie <[email protected]>
@MisterMX thank you for the feedback! |
Also, @MisterMX you'll notice the failed |
E2E Tests are running successfully for the latest master: https://github.com/crossplane-contrib/provider-aws/actions/runs/5508575184. @zonybob you might have done some misconfiguration between |
Yes I'm sorry! Forgot all about the |
Signed-off-by: Ben McDonie <[email protected]>
@MisterMX build submodule updated and e2e-tests passed. Let me know how it all looks now. Thanks! |
…-permissionsboundary
Looking good for me except for some minor issues: Please encapsulate everything in a separate |
better error messages Signed-off-by: Ben McDonie <[email protected]>
@MisterMX thanks again for the response. New commits are up. I think I addressed everything this time (hopefully). |
@zonybob that looks good now. THank you very much for your contribution! One last thing: Can you please squash your changes into a single commit in order to keep the history short and concise? Then I can merge it. |
@MisterMX are you able to squash on the merge? If not, could you assist me with this? My |
@zonybob I could do half of that with Githubs "Squash and Merge" feature. However, it does not - for some reason - create a merge commit which is what we want as well. So we are left with squashing the commits manually. Squashing in git is comparably easy and can be achieved with an interactive rebase. There are a bunch of tutorials out there that can help understanding it. Essentially it is just |
Tested it locally and it seems only a single commit is merged anyways so it should be fine in this case. |
Ok, it wasn't. Seems like Github is doing something differently under the hood when merging. |
Description of your changes
This update causes the IAM User controller to also observe needed changes on the User permissions boundary and update it as needed. Part of this change also introduces the hopefully desirable side effect that
UpdateUser
is only called if needed (when the path changes.)Fixes #1080
I have:
make reviewable test
to ensure this PR is ready for review.How has this code been tested
This code has been tested against a factory environment where a number of IAM users are present and managed. Users were created, and boundaries were updated on the managed resource to observe the correct behavior in AWS.
IAM unit tests were also updated and run.