Repository navigation
Conversation
Replace panic() call in ConvertToOriginClusterRolesOrDie() and ConvertToOriginClusterRoleBindingsOrDie() with error return value. Callers take care of proper error handling. See: openshift#15827 Signed-off-by: Christian Heimes <[email protected]>
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: tiran Assign the PR to them by writing The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these OWNERS Files:You can indicate your approval by writing |
|
Rather than do this, how about we make everything use RBAC roles instead and eliminate the conversion entirely. |
|
@deads2k Yes, that's the next step. |
Guess I'm not sure why I'd take this step in the interim. |
| if err := kapi.Scheme.Convert(&in[i], newRole, nil); err != nil { | ||
| errs = append(errs, fmt.Errorf("error converting %q: %v", in[i].Name, err)) | ||
| continue | ||
| return nil, fmt.Errorf("error converting %q: %v", in[i].Name, err) |
There was a problem hiding this comment.
I'm not sure we should bail out on first error.seem like reporting all failures is a property that should be maintained
|
I'm closing my PR in favor of PR #16033. It removes the function |
Replace panic() call in ConvertToOriginClusterRolesOrDie() and
ConvertToOriginClusterRoleBindingsOrDie() with error return value.
Callers take care of proper error handling.
@openshift/sig-security
See: #15827
Signed-off-by: Christian Heimes [email protected]