Can't add a certain team as a GitHub environment protection rule's reviewer
Asked Answered
B

3

6

I have a team called "team-core" in GitHub.

This team has Write access to a certain private repository:

"Team core" has Write access to the repo

I have an environment "qa" set up for this repository in GitHub.

I want to add a protection rule to that environment, requiring a review from anyone on Team core.

However, despite the fact that "Team core" has write access (docs say they only need Read access), they are not showing up in the list of possible reviewers for this rule.

"Team core" does not show up in the list of possible

4 other teams do show up in this menu (1 with Read, 2 with Write, and 1 with Admin roles for the repo).

How can I make Team core a reviewer for the environment protection rule?

Additional findings

This team can be added for options in branch protection rules for the same repo that allow you to input a team ("Restrict who can dismiss pull request reviews", "Allow specified actors to bypass required pull requests", and "Restrict who can push to matching branches").

Baudin answered 6/9, 2022 at 23:0 Comment(0)
K
0

I had a similar issue that was resolved by changing the team from "Secret" to "Visible" or "Closed"

Another possible issue is the account, which used to be limited to GitHub Enterprise only (https://github.com/orgs/community/discussions/30156#discussioncomment-3488144), but has since expanded:

For access to environments, environment secrets, and deployment branches in private or internal repositories, you must use GitHub Pro, GitHub Team, or GitHub Enterprise.

Kassandrakassaraba answered 30/8, 2023 at 22:13 Comment(0)
S
0

Fixed on our side by adding repository in team repositories with write permissions

Stagecraft answered 23/7, 2024 at 8:37 Comment(0)
H
0

I faced a similar problem today where even though a team had access to all repos in an organisation because they were granted access at the org level they still could not be assigned as the reviewer on an environment for any of the repositories.

I resolved this by adding the team to the specific repository I was interested in, now the team was available to be assigned so I assigned it as the reviewer on the environment.

Hearst answered 14/8, 2024 at 11:47 Comment(0)

© 2022 - 2025 — McMap. All rights reserved.