-
Notifications
You must be signed in to change notification settings - Fork 125
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
OSD-22635: use elevation for oc execs #585
Conversation
@typeid: This pull request references OSD-22635 which is a valid jira issue. Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the task to target the "4.17.0" version, but no target version was set. In response to this:
Instructions 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 openshift-eng/jira-lifecycle-plugin repository. |
@@ -106,7 +115,7 @@ func (o *detachStuckVolumeOptions) detachVolume(clusterID string) error { | |||
} | |||
|
|||
// Following function gets the volumeID & region of pv for non running state pod & value into global variable | |||
func getVolumeID(clientset *kubernetes.Clientset, namespace, selector string) error { |
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.
Parameter was unused
} | ||
|
||
func ListSilence(clusterID string) { | ||
func ListSilence(cmd *listSilenceCmd) { |
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.
What do you think of just having that function take two parameters - a "reason" and a "clusterId"? This decouples it entirely from the cobra library and makes it a bit easier to test.
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.
Hmm, this is actually already decoupled. listSilenceCmd
is just a struct and has nothing to do with cobra, maybe the name is causing confusion? But this is how we do it for the other commands as well (before this change).
/lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: AlexVulaj, typeid The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
@typeid: all tests passed! Full PR test history. Your PR dashboard. Instructions 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-sigs/prow repository. I understand the commands that are listed here. |
As part of
https://issues.redhat.com/browse/OSD-22635
oc exec
andoc debug
have been gated to backplane cluster admin. We now need to elevate ofoc exec
.SOPs have already been updated for the changes (see here).
https://issues.redhat.com/browse/OSD-22635