Uploaded image for project: 'Bitbucket Data Center'
  1. Bitbucket Data Center
  2. BSERV-19463

Forking failures in Bitbucket DC docker containers due to new git clone protection feature

XMLWordPrintable

      Update

      The affected Docker images have now been fixed and have been republished. Customers who were affected will need to download the image again using docker pull to get the fixed version. For example, if they were using the 8.9.12 image they will need to run the following and then start the container using the updated image.

      docker pull atlassian/bitbucket:8.9.12
      

      Issue Summary

      The latest versions of Git integrated into the Bitbucket Data Center Docker images have introduced a clone protection feature that is currently preventing users from successfully forking repositories. This Git feature, designed to enhance security by checking for an active core.hooksPath configuration, inadvertently blocks the git clone command used by the forking process for repositories.

      Steps to Reproduce

      Attempt to fork an existing repository in Bitbucket using an affected Docker image.

      Expected Results

      The fork should be successfully created.

      Actual Results

      The fork can't be created with an error similar to the following displayed.

      'git clone --bare --shared --template=/var/atlassian/application-data/bitbucket/shared/config/git/templates /var/atlassian/application-data/bitbucket/shared/data/repositories/1 /var/atlassian/application-data/bitbucket/shared/data/repositories/2' exited with code 128 saying: Cloning into bare repository '/var/atlassian/application-data/bitbucket/shared/data/repositories/2'... fatal: active `core.hooksPath` found in the local repository config: ../../../config/git/hooks For security reasons, this is disallowed by default. If this is intentional and the hook should actually be run, please run the command again with `GIT_CLONE_PROTECTION_ACTIVE=false`
      

      Workaround

      To temporarily resolve this issue and restore functionality, affected users can bypass the Git clone protection feature by passing the GIT_CLONE_PROTECTION_ACTIVE=false environment variable to their Docker container.

              Unassigned Unassigned
              74d6667aa35c Josh Aguilar
              Votes:
              0 Vote for this issue
              Watchers:
              8 Start watching this issue

                Created:
                Updated:
                Resolved: