Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit6c64621

Browse files
committed
Add more perms to org members
1 parentdcf52f8 commit6c64621

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

‎coderd/rbac/roles.go‎

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -301,8 +301,6 @@ func ReloadBuiltinRoles(opts *RoleOptions) {
301301
// Users cannot do create/update/delete on themselves, but they
302302
// can read their own details.
303303
ResourceUser.Type: {policy.ActionRead,policy.ActionReadPersonal,policy.ActionUpdatePersonal},
304-
// Users can create provisioner daemons scoped to themselves.
305-
ResourceProvisionerDaemon.Type: {policy.ActionRead,policy.ActionCreate,policy.ActionRead,policy.ActionUpdate},
306304
})...,
307305
),
308306
OrgMember:map[string][]Permission{},
@@ -453,7 +451,13 @@ func ReloadBuiltinRoles(opts *RoleOptions) {
453451
User: []Permission{},
454452
OrgMember:map[string][]Permission{
455453
organizationID.String():Permissions(map[string][]policy.Action{
456-
ResourceWorkspace.Type:ResourceWorkspace.AvailableActions(),
454+
// Users can create provisioner daemons scoped to themselves.
455+
// All provisioners still need an organization relation as well.
456+
ResourceProvisionerDaemon.Type:ResourceProvisionerDaemon.AvailableActions(),
457+
// All group members can read their own group membership
458+
ResourceGroupMember.Type: {policy.ActionRead},
459+
ResourceInboxNotification.Type: {policy.ActionCreate,policy.ActionRead,policy.ActionUpdate},
460+
ResourceWorkspace.Type:ResourceWorkspace.AvailableActions(),
457461
// Reduced permission set on dormant workspaces. No build, ssh, or exec
458462
ResourceWorkspaceDormant.Type: {policy.ActionRead,policy.ActionDelete,policy.ActionCreate,policy.ActionUpdate,policy.ActionWorkspaceStop,policy.ActionCreateAgent,policy.ActionDeleteAgent},
459463
// Can read their own organization member record

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp