Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

This article explains how to add Bitbucket server repository from a specific Bitbucket project in Bamboo using Bamboo Command Line Interface (CLI).

Instructions

  • To add

...

...

...

  • target Bitbucket project with parameter field and value as repository.stash.projectKey= as shown below:

    Code Block
    themeMidnight
    --action addRepository --repository “Testing” --repositoryKey BITBUCKET_SERVER --branch master --targetServer "$Bitbucket_Server" --targetUser "$Bitbucket_User" --targetPassword "$Bitbucket_Password" --field repository.stash.projectKey=TEST


  • To add plan repository, combine addRepository with plan, repositoryrepositoryKey, branch, targetServer, targetUser, targetPassword,

...

  • target Bitbucket project with parameter field and value as repository.stash.projectKey= as shown below:

    Code Block
    themeMidnight
    --action addRepository --plan "TES-TRAIN" --repository “Testing” --repositoryKey BITBUCKET_SERVER --branch master --targetServer "$Bitbucket_Server" --targetUser "$Bitbucket_User" --targetPassword "$Bitbucket_Password" --field repository.stash.projectKey=TEST


  • Additionally name parameter can be used to name the repository in Bamboo. 
Info

It is recommended to test this scenario in a test environment or run the action with the --simulate parameter to verify the behavior before deploying.

...