Skip to content

Commit 1ec8d5a

Browse files
isaacmbrownCopilot
andauthored
Allow periodic scanning of inactive repos [GA] (#61312)
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
1 parent 033fec6 commit 1ec8d5a

6 files changed

Lines changed: 33 additions & 3 deletions

File tree

content/code-security/how-tos/find-and-fix-code-vulnerabilities/configure-code-scanning/configure-code-scanning.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ Your repository is eligible for default setup for {% data variables.product.prod
7777
1. Optionally, to view your default setup configuration after enablement, select {% octicon "kebab-horizontal" aria-label="Menu" %}, then click **{% octicon "gear" aria-hidden="true" aria-label="gear" %} View {% data variables.product.prodname_codeql %} configuration**.
7878

7979
> [!NOTE]
80-
> If no pushes and pull requests have occurred in a repository with default setup enabled for 6 months, the weekly schedule will be disabled to save your {% data variables.product.prodname_actions %} minutes.
80+
> If no pushes and pull requests have occurred in a repository with default setup enabled for 6 months, the weekly schedule will be disabled to save your {% data variables.product.prodname_actions %} minutes.{% ifversion code-scanning-inactive-repos %} Organization owners can enable monthly scans of inactive repositories. For more information, see [AUTOTITLE](/code-security/securing-your-organization/enabling-security-features-in-your-organization/configuring-global-security-settings-for-your-organization#continuing-scans-on-inactive-repositories).{% endif %}
8181
8282
{% ifversion fpt or ghec %}
8383

content/code-security/how-tos/find-and-fix-code-vulnerabilities/manage-your-configuration/edit-default-setup.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,19 @@ For more information about {% data variables.product.prodname_codeql %} model pa
8383

8484
1. The model packs will be automatically detected and used when {% data variables.product.prodname_code_scanning %} runs on any repository in the organization with default setup enabled.
8585

86+
{% ifversion code-scanning-inactive-repos %}
87+
88+
## Continuing scans on inactive repositories
89+
90+
{% data reusables.code-scanning.inactive-repos-scan %} You can override this behavior in an organization, though the scan period is not configurable.
91+
92+
{% data reusables.profile.access_org %}
93+
{% data reusables.organizations.org_settings %}
94+
{% data reusables.security-configurations.display-global-settings %}
95+
1. In the "{% data variables.product.prodname_code_scanning_caps %}" section, enable the **Keep scheduled scans running every 30 days for inactive repositories** setting.
96+
97+
{% endif %}
98+
8699
## Further customization
87100

88101
If you need to change any other aspects of your {% data variables.product.prodname_code_scanning %} configuration, consider configuring advanced setup. See [AUTOTITLE](/code-security/code-scanning/creating-an-advanced-setup-for-code-scanning/configuring-advanced-setup-for-code-scanning).

content/code-security/how-tos/secure-at-scale/configure-organization-security/configure-specific-tools/code-scanning-at-scale.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,9 @@ A repository must meet all the following criteria to be eligible for default set
3333

3434
You can enable default setup for all eligible repositories in your organization. For more information, see [AUTOTITLE](/code-security/securing-your-organization/introduction-to-securing-your-organization-at-scale/about-enabling-security-features-at-scale).
3535

36-
### Extending {% data variables.product.prodname_codeql %} coverage in default setup
36+
### Configuring default setup features
3737

38-
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 [AUTOTITLE](/code-security/code-scanning/managing-your-code-scanning-configuration/editing-your-configuration-of-default-setup#extending-coverage-for-all-repositories-in-an-organization).
38+
Through your organization's security settings page, you can customize default setup for all eligible repositories, such as extending coverage using model packs. See [AUTOTITLE](/code-security/code-scanning/managing-your-code-scanning-configuration/editing-your-configuration-of-default-setup).
3939

4040
## Configuring default setup for a subset of repositories in an organization
4141

content/code-security/how-tos/secure-at-scale/configure-organization-security/establish-complete-coverage/configure-global-settings.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,9 @@ You can customize several {% data variables.product.prodname_global_settings %}
105105
{% ifversion code-scanning-autofix %}* [Enabling {% data variables.copilot.copilot_autofix_short %} for {% data variables.product.prodname_codeql %}](#enabling-copilot-autofix-for-codeql){% endif %}
106106
* [Recommending the extended query suite for default setup](#recommending-the-extended-query-suite-for-default-setup)
107107
* [Expanding {% data variables.product.prodname_codeql %} analysis](#expanding-codeql-analysis)
108+
{%- ifversion code-scanning-inactive-repos %}
109+
* [Continuing scans on inactive repositories](#continuing-scans-on-inactive-repositories)
110+
{%- endif %}
108111

109112
{% endif %}
110113

@@ -124,6 +127,14 @@ You can select **{% data variables.copilot.copilot_autofix_short %}** to enable
124127

125128
You can expand {% data variables.product.prodname_codeql %} analysis coverage for all repositories in your organization that use default setup by configuring {% data variables.product.prodname_codeql %} model packs. Model packs extend the {% data variables.product.prodname_codeql %} analysis to recognize additional frameworks and libraries that are not included in the standard {% data variables.product.prodname_codeql %} libraries. This global configuration applies to repositories using default setup and allows you to specify model packs published via the container registry. For more information, see [AUTOTITLE](/code-security/how-tos/scan-code-for-vulnerabilities/manage-your-configuration/editing-your-configuration-of-default-setup#extending-coverage-for-all-repositories-in-an-organization).
126129

130+
{% ifversion code-scanning-inactive-repos %}
131+
132+
### Continuing scans on inactive repositories
133+
134+
{% data reusables.code-scanning.inactive-repos-scan %} You can select **Keep scheduled scans running every 30 days for inactive repositories** to override this behavior in an organization. The scan period is not configurable.
135+
136+
{% endif %}
137+
127138
## Configuring global {% data variables.product.prodname_secret_scanning %} settings
128139

129140
{% data reusables.security-configurations.secret-scanning-security-configs-summary %}
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# Ref: 22601
2+
versions:
3+
fpt: '*'
4+
ghec: '*'
5+
ghes: '>= 3.22'
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
By default, {% data variables.product.prodname_code_scanning %} default setup pauses weekly scheduled scans on repositories that have had no commits pushed or pull requests opened for 180 days.

0 commit comments

Comments
 (0)