-
Notifications
You must be signed in to change notification settings - Fork 228
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
[SURE-8832] fix: add check for external rules while updating roleTemplate #1389
Conversation
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.
lgtm
Hi @matttrach, could you help arrange the backporting if it is necessary?
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.
The code is reasonable here, and the unit tests pass.
@pratikjagrut would you mind signing your commit? Then I will get this merged into the proper branches. |
96ddbd7
to
586d303
Compare
…late - Modified the roleTemplate update logic to include a check for external rules. - Added a condition to ensure external rules are only updated when the `external` flag is set. - Set `externalRules` to `nil` if the `external` flag is not set. Signed-off-by: Pratik Jagrut <[email protected]>
586d303
to
a68b9c6
Compare
@matttrach I've signed the commit. |
I will backport this to release/v5 and release/v4 in separate PRs. |
…late (rancher#1389) Signed-off-by: Pratik Jagrut <[email protected]> (cherry picked from commit 4d338b6)
…late (rancher#1389) Signed-off-by: Pratik Jagrut <[email protected]> (cherry picked from commit 4d338b6)
Issue: #1381
Problem
JIRA issue: https://jira.suse.com/browse/SURE-8832
When attempting to update a RoleTemplate using the rancher2 tf provider v4.2.0 you will get the following error:
Solution
external
flag is set.externalRules
tonil
if theexternal
flag is not set.Testing
Engineering Testing
Manual Testing
The fix was tested using the reproduction steps, and the issue was resolved.
Automated Testing
QA Testing Considerations
Regressions Considerations