Skip to main content

Настройка настройки по умолчанию для сканирования кода в масштабе

Вы можете быстро настроить code scanning для репозиториев в организации с помощью настройки по умолчанию.

Кто может использовать эту функцию?

Владельцы организации, руководители безопасности и члены организации с ролью администратора

Code scanning доступен для следующих типов репозитория:

  • Общедоступные репозитории для GitHub.com
  • Репозитории, принадлежащие организации, на GitHub Team, GitHub Enterprise Cloud или GitHub Enterprise Server, с включённым GitHub Advanced Security .

With default setup for code scanning, you can quickly secure code in repositories across your organization. For more information, see About setup types for code scanning.

For repositories that are not suitable for default setup, you can configure advanced setup at the repository level, or at the organization level using a script.

Prerequisites

A repository must meet all the following criteria to be eligible for default setup:

  • Advanced setup for code scanning is not already enabled.
  • GitHub Actions is enabled.
  • GitHub Advanced Security is enabled.

Configuring default setup for all eligible repositories in an organization

You can enable default setup for all eligible repositories in your organization. For more information, see About enabling security features at scale.

Extending CodeQL coverage in default setup

Through your organization's security settings page, you can extend coverage in default setup using model packs for all eligible repositories in your organization. For more information, see Editing your configuration of default setup.

Configuring default setup for a subset of repositories in an organization

You can filter for specific repositories you would like to configure default setup for. For more information, see Applying a custom security configuration.

Configuring merge protection for all repositories in an organization

You can use rulesets to prevent pull requests from being merged when one of the following conditions is met:

  • A required tool found a code scanning alert of a severity that is defined in a ruleset.
  • A required code scanning tool's analysis is still in progress.
  • A required code scanning tool is not configured for the repository.

For more information, see Set code scanning merge protection. For more general information about rulesets, see About rulesets.