Skip to content

Commit

Permalink
Add RBAC permissions for edit and admin roles
Browse files Browse the repository at this point in the history
Signed-off-by: Roman Mohr <[email protected]>
  • Loading branch information
rmohr committed Sep 20, 2022
1 parent 5e872d0 commit 5ae5f4c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions pkg/virt-operator/resource/generate/rbac/cluster.go
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,7 @@ func newAdminClusterRole() *rbacv1.ClusterRole {
Resources: []string{
"virtualmachineinstances/console",
"virtualmachineinstances/vnc",
"virtualmachineinstances/vnc/screenshot",
VMInstancesGuestOSInfo,
VMInstancesFileSysList,
VMInstancesUserList,
Expand Down Expand Up @@ -272,6 +273,7 @@ func newEditClusterRole() *rbacv1.ClusterRole {
Resources: []string{
"virtualmachineinstances/console",
"virtualmachineinstances/vnc",
"virtualmachineinstances/vnc/screenshot",
VMInstancesGuestOSInfo,
VMInstancesFileSysList,
VMInstancesUserList,
Expand Down
2 changes: 2 additions & 0 deletions tests/access_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -413,6 +413,7 @@ var _ = Describe("[rfe_id:500][crit:high][arm64][vendor:[email protected]][level
Entry("[test_id:2921]given a vmi (softreboot)", "virtualmachineinstances/softreboot", "update"),
Entry("[test_id:2921]given a vmi (console)", "virtualmachineinstances/console", "get"),
Entry("[test_id:2921]given a vmi (vnc)", "virtualmachineinstances/vnc", "get"),
Entry("[test_id:2921]given a vmi (vnc/screenshot)", "virtualmachineinstances/vnc/screenshot", "get"),
)
})

Expand Down Expand Up @@ -454,6 +455,7 @@ var _ = Describe("[rfe_id:500][crit:high][arm64][vendor:[email protected]][level
Entry("[test_id:2921]given a vmi (softreboot)", "virtualmachineinstances/softreboot", "update"),
Entry("[test_id:2921]given a vmi (console)", "virtualmachineinstances/console", "get"),
Entry("[test_id:2921]given a vmi (vnc)", "virtualmachineinstances/vnc", "get"),
Entry("[test_id:2921]given a vmi (vnc/screenshot)", "virtualmachineinstances/vnc/screenshot", "get"),
Entry("[test_id:2921]given a vmi (guestosinfo)", "virtualmachineinstances/guestosinfo", "get"),
)
})
Expand Down

0 comments on commit 5ae5f4c

Please sign in to comment.