Skip to end of banner
Go to start of banner

How to add Bitbucket server repository from specific Bitbucket project in Bamboo using Bamboo Command Line Interface (CLI)

Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 6 Next »

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

Instructions

  1. To add an global repository, combine addRepository with repositoryrepositoryKey, branch, targetServer, targetUser, targetPassword, target Bitbucket project with parameter field and value as repository.stash.projectKey= as shown below:

    --action addRepository --repository “Testing” --repositoryKey BITBUCKET_SERVER --branch master --targetServer "$Bitbucket_Server" --targetUser "$Bitbucket_User" --targetPassword "$Bitbucket_Password" --field repository.stash.projectKey=TEST
  2. 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:

    --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
  3. Additionally name parameter can be used to name the repository in Bamboo. 


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.

  • No labels