Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add security-manager to github_org.rb #136

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

mrecachinas
Copy link
Member

@mrecachinas mrecachinas commented Feb 13, 2025

This pull request includes an update to the GitHubOrg class in the lib/entitlements/backend/github_org.rb file to support a new role. The most important change is the addition of the "security-manager" role to the ORGANIZATION_ROLES hash.

/cc https://github.com/github/entitlements/pull/101743#issuecomment-2656664339
/cc https://github.com/github/security-services/issues/190

@Copilot Copilot bot review requested due to automatic review settings February 13, 2025 19:34
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

PR Overview

This PR updates the GitHubOrg class by adding support for a new role: "security-manager".

  • Added a new mapping for "security-manager" in the ORGANIZATION_ROLES hash.
  • Ensured proper comma separation in the hash entries.

Changes

File Description
lib/entitlements/backend/github_org.rb Added "security-manager" role to the ORGANIZATION_ROLES hash

Copilot reviewed 1 out of 1 changed files in this pull request and generated no comments.

Tip: Copilot only keeps its highest confidence comments to reduce noise and keep you focused. Learn more

@jasonmacgowan
Copy link
Contributor

jasonmacgowan commented Feb 18, 2025

Org roles API endpoint suggests this should be security_manager instead of security-manager. I'm also double checking that this plugin can manage these org roles because I think they use a different API now that I'm looking into it more.

$ gh api \
        -H "Accept: application/vnd.github+json" \
        -H "X-GitHub-Api-Version: 2022-11-28" \
        /orgs/github/organization-roles --jq .roles[].name
Manage Runners
API Insights Viewers
all_repo_admin
all_repo_maintain
all_repo_read
all_repo_triage
all_repo_write
ci_cd_admin
security_manager

@mrecachinas
Copy link
Member Author

Ah thanks, wasn't sure if it was - or _.

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.

2 participants