Ensure BitBucket pull requests require at least 2 approvals

Error: BitBucket pull requests require less than approvals
Bridgecrew Policy ID: BC_REPO_BITBUCKET_1
Checkov Check ID: CKV_BITBUCKET_1
Severity: MEDIUM

BitBucket pull requests require less than approvals


In Bitbucket, repository administrators can require that all pull requests receive a specific number of approving reviews before someone merges the pull request into a protected branch.

If a collaborator attempts to merge a pull request with pending or rejected reviews into the protected branch, the collaborator will receive an error message.

Fix - Runtime

  1. Login to Bitbucket
  2. Select your repository
  3. Select Repository settings
  4. Select Branch restrictions
  5. Add a restriction
  6. Under Merge settings check Minimum number of approvals and select 2
  7. Save