knative / serving-operator

DEPRECATED: Development continues in https://github.com/knative/operator/
Apache License 2.0
39 stars 45 forks source link

Delete (Cluster)Role(Bindings) as a final cleanup step. #359

Closed Cynocracy closed 4 years ago

Cynocracy commented 4 years ago

This allows us to take advantage of the permissions granted to cluster admins when performing cleanup. If the approach in https://github.com/knative/serving-operator/pull/291 is approved, this will become necessary. Additionally, it makes sense to remove roles as the final step to allow human Operators to modify any resources they may have permissions on as a result of the Knative installation (that is, we should not remove any access until we are 'almost done' cleaning up).

/lint

Proposed Changes

Release Note

Delete roles and rolebindings as a final cleanup step.
Cynocracy commented 4 years ago

/assign @k4leung4

k4leung4 commented 4 years ago

maybe add a unit test?

jcrossley3 commented 4 years ago

/lgtm

Cynocracy commented 4 years ago

@k4leung4 re: unit test, I'm not sure I'd like to expand the scope of this PR to include one.

Perhaps I can work on one in a separate issue/change?

k4leung4 commented 4 years ago

@Cynocracy works for me. just want to make sure we verify behavior changes as we dont really know when it stops working.

/approve /lgtm

knative-prow-robot commented 4 years ago

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: Cynocracy, k4leung4

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: - ~~[OWNERS](https://github.com/knative/serving-operator/blob/master/OWNERS)~~ [k4leung4] Approvers can indicate their approval by writing `/approve` in a comment Approvers can cancel approval by writing `/approve cancel` in a comment
Cynocracy commented 4 years ago

Gotcha, there are integration tests here: https://github.com/knative/serving-operator/blob/master/test/resources/verify.go#L190

Filed https://github.com/knative/serving-operator/issues/361 to add unit tests.