Drata now supports GitHub organizational rulesets in our GitHub integration for Version Control. Follow these steps to enable the Drata Autopilot system access to your organizational rulesets and apply these rulesets to the Formal Code Review Process test.
Note: Due to recent GitHub updates, Drata can now access both organizational and repository rulesets with Read-only permissions, eliminating the need for elevated access. Organization and repository rulesets are supported.
Prerequisite
To use GitHub rulesets, ensure your setup meets the following requirements:
Use a GitHub Enterprise Cloud, GitHub Enterprise Server.
Drata supports both organization and repository rulesets.
You must include ALL branches or the Default Branch. Default branches must be directly targeted, as paths are not supported.
One or more approvers must be specified.
Grant Administration Read permissions under Organization permissions.
Grant Administration Read permissions
To grant Administration Read permissions under Organization permissions, you must be a GitHub Organization Owner or Admin and the Drata GitHub integration must already be installed in the organization
Log in to GitHub as an organization owner or admin.
Select Your organizations, then choose the relevant organization.
Select Settings in the organization navigation.
In the left sidebar, navigate to GitHub Apps. In some orgs, this appears as Integrations → GitHub Apps.
Find Drata in the list of installed GitHub Apps and select Configure.
Review Organization permissions
Scroll to Organization permissions.
Locate Administration.
Set Administration to Read-only.
Save changes
Set up organizational rulesets in GitHub
To configure organizational:
Log in as an Admin in GitHub and select Your organizations.
Select the relevant organization.
Navigate to Settings.
Expand Repository and select Repository rulesets.
Here, you can start to configure your rulesets.
Create a repository ruleset
To create or edit a ruleset:
Select the New branch ruleset or select an existing ruleset to edit.
Enter a Ruleset Name.
Set Enforcement Status to Active.
Bypass list is optional.
Choose Target repositories to be one of the following:
All repositories
Dynamic list by name
Select repositories
If selected, continue and add specific repositories.
Note: Some configurations, such as Target: Dynamic list by property, are currently not supported.
Under Target branches, choose Include default branch or Include all branches.
Configure Branch protections:
Require a pull request before merging.
Specify Required approvals (must be 1 or more).
Save changes.
Troubleshooting
If issues arise, use the JSON results from the Formal Code Review monitoring test to identify any failed repositories. Only repositories with failures are displayed; passing repositories will not appear in this list.






