Skip to content

feat: enable Coder Agents for organization members - #28186

Open
ibetitsmike wants to merge 1 commit into
mainfrom
mike/codagt-554-enable-agents-by-default
Open

feat: enable Coder Agents for organization members#28186
ibetitsmike wants to merge 1 commit into
mainfrom
mike/codagt-554-enable-agents-by-default

Conversation

@ibetitsmike

Copy link
Copy Markdown
Collaborator

Summary

  • make Coder Agents available to organization members without a separate built-in role
  • remove the obsolete role from backend and frontend role surfaces
  • migrate stored assignments and update authorization, UI, documentation, and regression coverage

Validation

  • make gen
  • make lint
  • repository pre-commit checks
  • targeted RBAC, migration, chat API, enterprise, site, Storybook, and race tests
  • git diff --check

Rollback note

The down migration restores effective access broadly because it cannot reconstruct which users previously held the removed role.

Mux created this pull request on Mike's behalf.

@linear-code

linear-code Bot commented Aug 15, 2026

Copy link
Copy Markdown

CODAGT-554

@github-actions

Copy link
Copy Markdown

Docs preview

Check off each page once it's been reviewed. If a page changes in a later push, its checkbox clears automatically so it gets a fresh look. Pages not yet wired into the docs navigation aren't listed here.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: b0ff6615d4

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +8 to +9
SET default_org_member_roles = array_append(default_org_member_roles, 'agents-access')
WHERE NOT ('agents-access' = ANY(default_org_member_roles));

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Exclude service accounts from rollback access grants

When this migration is rolled back, adding agents-access to default_org_member_roles grants it to service accounts as well, because GetAuthorizationUserRoles unions organization defaults into every membership, including accounts receiving the separate organization-service-account role. This defeats the new explicit omission of chat permissions for service accounts and gives machine credentials Coder Agents access after a production rollback. Restore the role only on regular users' membership rows, rather than making it an organization default.

Useful? React with 👍 / 👎.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant