You're on your way to the next level! Join the Kudos program to earn points and save your progress.
Level 1: Seed
25 / 150 points
1 badge earned
Challenges come and go, but your rewards stay with you. Do more to earn more!
What goes around comes around! Share the love by gifting kudos to your peers.
Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!
Join now to unlock these features and more
I'm leveraging all of the goodness of Spec Plans, but it depends heavily on an existing Linked Repository.
Here is what I have so far:
Step 1 - Use the Bitbucket API to setup a code repository [scripted]
Step 2 - Log into Bitbucket, create 'Linked Repository' (LR) to new code repo [manual]
Step 3 - Execute java Spec Plan to create a Bamboo Build Plan (linked to the LR) [scripted]
You can see the significant interrupt in my attempt to create a push-button setup.
The closest I find is Bob Swift's CLI tool. While neat, I don't have local Bamboo Admin access.
All actions must be via API or remotely.
Thanks in advance!
Try Bamboo Specs for linked repositories management
BambooServer bambooServer = new BambooServer("http://localhost:6990/bamboo");
final GitRepository gitRepository = new GitRepository()
Thanks Alexey, but a recent article indicates that global linked repository are preferred and that manually configured repository are to be deprecated. So I was hoping to adopt the preferred method.
@Hema , it will create repository. Then you need to enable Specs detection https://docs.atlassian.com/atlassian-bamboo/REST/6.9.0/#d2e4449
curl -u admin:admin -X PUT http://localhost:8085/rest/api/latest/repository/123/enableCi
Then you also need to grant permissions to particular projects or grant access for this repo to all your projects.
Unfortunately there's no Rest API to get repo id by its name so you need to get it manually through UI. You can watch and vote for https://jira.atlassian.com/browse/BAM-20007 to address it.
Hi @Alexey Chystoprudov ,
Thanks for response.
I created plan using bitbucket spec repository but when I saw bamboo plan, it is not allowing to edit on bamboo. Showing message like edit this plan using bitbucket spec repository. So can you please help me if I want to create plan using butbucket repo as well modify changes using bamboo UI.
Also how to enable scan for bamboo spec using bamboo java spec
Once plan is managed by repository you can't edit it by UI. If you need to turn it off - publish it from local environment by command executed at bamboo-specs folder of your repo.
It's not possible to enable Bamboo Specs property of repository from Bamboo Specs
I have created bamboo spec stored in bitbucket repository and created lonked repository in bamboo, enabled scan for spec. But when bamboo scan for spec, it is asking for ssh private and public key for plan repository stored in bitbucket RSS. If I mentioned public and private key then it publish plan repository in plan. So if any other user change in spec then will it work for him.
What exactly consists in public and private key ie is it specific to user
Bamboo does not provide the REST end point to create a new linked repository (yet as of Bamboo 6.4.1). I found an open feature request for this - BAM-18453
I recommend you vote for it and comment to get it prioritised.