You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Improve provisioner jobs RBAC with a PostgreSQL VIEW #16160
In #16029 we introduced a new RBAC resource called rbac.ResourceProvisionerJobs. However, the scope was limited to owners and template admins for now because proper expression (via RBACObject) requires that we also know the associated template or workspace (jobs refer only to template versions or workspace builds).
If we implement this as a PostgreSQL view which joins in the relevant template or workspace data, we can provisioner jobs to users as well (e.g. builds of their own workspace).
useful directions for RBACing InsertProvisionerJob from @deansheather
template_version_import jobs require either template_version:create on the org (if creating a new template) or template:update and template_version:create on the template (if pushing a new version)
template_version_dry_run jobs require permissions to workspace:create in the org as well as template_version:read on the specific template version
workspace_build jobs require workspace:update on the specific workspace as well as template_version:read on the specific template version
Activity
ibetitsmike commentedon May 19, 2025
useful directions for RBACing
InsertProvisionerJobfrom @deansheathertemplate_version_importjobs require eithertemplate_version:createon the org (if creating a new template) ortemplate:updateandtemplate_version:createon the template (if pushing a new version)template_version_dry_runjobs require permissions toworkspace:createin the org as well astemplate_version:readon the specific template versionworkspace_buildjobs requireworkspace:updateon the specific workspace as well astemplate_version:readon the specific template versionfeat(coderd): add queue-position-free provisioner job query (#28367)
feat(coderd): add queue-position-free provisioner job query (#28367)
zenithwolf1000 commentedon Nov 16, 2026
Closing due to inactivity.