1
0
mirror of synced 2025-12-30 12:02:01 -05:00
Files
docs/data/reusables/actions/workflows/required-workflow-prerequisites.md

3.0 KiB

  • {% data variables.product.prodname_actions %} must be enabled for a repository in the organization's settings in order for required workflows to run. Once enabled at an organization-level, required workflows will run even when {% data variables.product.prodname_actions %} is disabled in the repository's settings. For more information on managing {% data variables.product.prodname_actions %} in your organization's repositories, see "AUTOTITLE."
  • Required workflows are available for organizations and only in repositories where the organization's plan supports required status checks. If required status checks are not supported, the workflow will still run, but it will not be a required check and will not block merging. For more information about support for required status checks, see "AUTOTITLE."
  • The repository's default branch must match the organization's default branch setting in order for required workflows to run as required status checks. If the default branch names do not match, the workflow will still run, but it will not be a required check. For more information about managing default branch names, see "AUTOTITLE" and "AUTOTITLE."
  • For required workflows to run, the pull request's source repository must be in the same organization as the target repository. {% data variables.product.product_name %} will source the required workflow from {% ifversion actions-required-workflow-improvements %}a specified branch, tag, or commit SHA {% else %}the HEAD commit of the default branch {% endif %}from the repository containing the workflow.
  • Secrets used in a required workflow should be created at either the organization level or in the target repositories.
  • Secrets in the source repository will not be fetched when a workflow runs in the target repository. {% ifversion actions-required-workflow-improvements %}* When a workflow is run as a required workflow it will ignore all the filters in the on: section, for example: branches, branches-ignore, paths, types etc. The required workflow will run only for the pull_request and pull_request_target default events. For more information on default activity types, see "AUTOTITLE."{% endif %}
  • Required workflows are not automatically triggered on already existing pull requests even though they automatically appear as expected checks. To trigger required workflows for an already existing pull request, push a new change to that pull request.