Skip to content

[FEAT]: add support for pre-defined organization roles #2314

Description

@mkushakov

Describe the need

As announced https://github.blog/changelog/2024-07-10-pre-defined-organization-roles-that-grant-access-to-all-repositories/ Github has added support for pre-defined organisation roles.
To add new resource like github_team_organization_role similar to github_team_repository to assign team to pre-defined role.

resource "github_team" "some_team" {
  name        = "SomeTeam"
  description = "Some cool team"
}

resource "github_team_organization_role" "some_team_role" {
  team_id    = github_team.some_team.slug
  role = "all_repo_read"
}

API:

SDK Version

No response

API Version

No response

Relevant log output

No response

Code of Conduct

  • I agree to follow this project's Code of Conduct

Activity

  1. added
    Status: Triage
    Type: Feature
    on Jul 11, 2024
  2. added
    Status: Up for grabs
    and removed
    Status: Triage
    on Jul 15, 2024
  3. moved this from 🆕 Triage to 🔥 Backlog in 🧰 Octokit Activeon Jul 15, 2024
  4. akmalharith commented on Sep 6, 2024

    @akmalharith

    Workaround is to use REST API provider

    resource "restapi_object" "global_permissions" {
      for_each = var.global_permissions
    
      path = "/orgs/${var.organization_name}/organization-roles"
    
      object_id = local.global_permissions[each.value.permission]
    
      create_path  = "/orgs/${var.organization_name}/organization-roles/teams/${each.key}/{id}"
      update_path  = "/orgs/${var.organization_name}/organization-roles/teams/${each.key}/{id}"
      destroy_path = "/orgs/${var.organization_name}/organization-roles/teams/${each.key}/{id}"
    
      create_method = "PUT"
    
      data = jsonencode({})
    }
  5. github-actions commented on Jun 4, 2025

    @github-actions

    👋 Hey Friends, this issue has been automatically marked as stale because it has no recent activity. It will be closed if no further activity occurs. Please add the Status: Pinned label if you feel that this issue needs to remain open/active. Thank you for your contributions and help in keeping things tidy!

  6. added
    Status: Stale
    on Jun 4, 2025
  7. martinssipenko commented on Jun 4, 2025

    @martinssipenko
    Contributor

    Not stale

  8. removed
    Status: Stale
    on Jun 5, 2025
  9. Bradley-McCallion commented on Jun 9, 2025

    @Bradley-McCallion

    Any update on this?

  10. jay-dizzale commented on Jul 8, 2025

    @jay-dizzale

    This issue is not stale. The suggested solution with mastercard/restapi is working, but the provider is not gpg signed.

  11. moved this from Backlog to On Deck in Terraform Provideron Oct 14, 2025
  12. moved this from 🔥 Backlog to ✅ Done in 🧰 Octokit Activeon Oct 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Status: Up for grabsType: Feature

    Type

    No type

    Projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions