The following sections describe key features of PSRule for GitHub.
PSRule for GitHub includes pre-build rules for validating public and private repositories. Each rule includes additional information to help remediate issues.
Use the built-in rules to start enforcing release processes quickly. Then layer on your own rules as your organization's requirements mature. Custom rules can be implemented quickly and work side-by-side with built-in rules.
As new built-in rules are added and improved, download the latest PowerShell module to start using them.
GitHub repositories can be validated throughout their lifecycle to support a DevOps culture.
- Shift-left: Identify configuration issues and provide fast feedback in pull requests.
- Monitor continuously: Perform ongoing checks for configuration optimization opportunities.
PSRule for GitHub provides the following cmdlets that extract data for analysis:
- Export-GitHubRuleData - Export GitHub repository configuration.
PSRule uses modern PowerShell libraries at its core, allowing it to go anywhere PowerShell can go. The companion extension for Visual Studio Code provides snippets for authoring rules and documentation. PSRule runs on MacOS, Linux and Windows.
PowerShell makes it easy to integrate PSRule into populate CI systems. Additionally, PSRule has extensions for:
PSRule for GitHub (PSRule.Rules.GitHub
) can be installed locally using Install-Module
within PowerShell.
For additional installation options see install instructions.
Continue reading for FAQ relating to PSRule for GitHub. For general FAQ see PSRule - Frequently Asked Questions (FAQ), including:
More to come
You may already be using a unit test framework such as Pester to test infrastructure code. If you are, then you may have encountered the following challenges.
For a general PSRule/ Pester comparison see How is PSRule different to Pester?