Uploaded image for project: 'Bamboo Data Center'
  1. Bamboo Data Center
  2. BAM-26022

Reverting to "Full clones" and setting "Repository caching on Agents" enabled in Bamboo may result in shallow clones

      Issue Summary

      When a repository has Shallow clones enabled and it is decided to revert the change back to "Full Clones" strategy and "Repository caching on Agents" is also enabled, further checkouts will remain shallowed.

      This is reproducible on Data Center:

      Steps to Reproduce

      1. Configure a Linked Repository with a "Shallow clone" strategy
      2. Run a build and validate the .git/shallow file is created
      3. Modify the Linked Repository settings and set it to "Full Clones" + "Repository caching on Agents"
      4. Run a build and validate if the .git/shallow file was removed
      5. Go to the Agent and run git log on the build working directory

      Expected Results

      1. The .git/shallow should not exist
      2. The git log output should contain the complete repository history

      Actual Results

      1. The .git/shallow is still present
      2. The git log output shows a shallow clone with only HEAD revisions

      Workaround

      Option 1:

      1. Modify the Linked Repository and disable "Repository caching on Agents"
      2. Run the build on the Agent (and any other affected agents)
      3. Set the Linked Repository with enabled "Repository caching on Agents"

      Option 2:

      1. Clean all Agents working directories for that Plan, including .git contents
      2. Run a build normally

            [BAM-26022] Reverting to "Full clones" and setting "Repository caching on Agents" enabled in Bamboo may result in shallow clones

            There are no comments yet on this issue.

              73868399605e Eduardo Alvarenga
              73868399605e Eduardo Alvarenga
              Affected customers:
              0 This affects my team
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved: