youngmon/atlassian-qna huggingface dataset:
bamboo : changing a plans repository configuration programtically
Asked by Adam Downer:

Hi,

I am trying to set up Bamboo 4.2.1 to provide a self service plan creation facility without having to grant all users admin access.

So far I have created a project that contains a build plan that invokes the Atlassian CLI tool (also installed on the box) to clone another project, which is my standard build template.

The template project consists of one plan which invokes maven to perform a 'clean deploy' build. The plans default repository is set to a place holder. Nothing else is altered from defaults in this template project.

I 'run customised' the plan which invokes the atlassian cli tool specifying a new project name and proper URL as variables.

The cli tool correctly clones the project under the new name I specify, which is great, but I can't find a way of getting the cli tool to update the plans default repository URL.

Is there a way to achieve the configuration change I am after unsing the cli tool or can anyone suggest an alternate method of achieving this self service function.

What I am thinking is along the lines of the :

```
bamboo --action updatePlan --build "ZBAMBOOCLI7938965-checkout1" --fields "repositoryURL:my.project.repo.com"
```

I have looked in the cli help and example files as well as the bamboo rest api documentation and no solution presents itself.

Thanks in advance


Answers:
author: Radhika Cargo
body: I have a bamboo that is turning yellow, but I'm not over watering it.


author: James Dumay
body: You can use [Bamboo variables](https://confluence.atlassian.com/display/BAMBOO/Using+global,+plan+or+build-specific+variables) in all of the fields of the repository plugin and then [execute via REST the variables you want to subsitute at runtime](http://docs.atlassian.com/bamboo/REST/4.0/#idp263696).

comments: author: Adam Downer
body: thanks James, I have the URL i need already accessible as part of a script. What I am trying to do is to permanently alter the repository URL for the newly cloned plan so that non customised runs will use that URL rather than the placeholder I have in the template. I can not find an entry in the REST API or the CLI tool which allows me to manipulate the plans repository URL setting. Any further suggestions?


author: PiotrA
body: Hm... how about crafting a BambooTask (plugin), executed as a part of your build plan that invokes the CLI tool, that would manipulate and update the repositoryUrl directly in the Bamboo java API?


author: Adam Downer
body: the question remains what CLI command would I execute to manipulate the repositoryURL? I can't see anything in the CLI examples to would do this.
Unability to create a new project
Asked by Gilles Bellefontaine:

Hi,

When I try to create a 2nd project via the create new link ([https://chugulu.atlassian.net/secure/admin/AddProject!default.jspa?nextAction=browseproject\&src=admingadget](https://chugulu.atlassian.net/secure/admin/AddProject%21default.jspa?nextAction=browseproject&src=admingadget)) on the dashboard, the system tells me :

Access Denied

It seems that you have tried to perform an operation which you are not permitted to perform.

If you think this message is wrong, please contact your JIRA administrators.

I am an JIRA admin so I don't understand why I do not have permission to do so.

Thank you for your support.

Regards,


Answers:
author: Gilles Bellefontaine
body: I just had to desactivate Bamboo


author: Christian Czaia _Decadis AG_
body: You're on a "on demand "instance, right? Seems like you're not a JIRA administrator...


Tags: project
Maven dependency Processor can't find parent project.
Asked by Jonathon Roberts:

Hello,

We've recently been getting a problem with the Maven Dependency Processor failing to find the the parent pom build project and then failing our build. The actual maven build builds ok.

I've got a maven module projects setup to build the modules independently and a parent project which just publishes a pom (with -N). We've been using automatic dependency management. I recently renamed the pom versions from a "1.0.0-SNAPSHOT" to just a "trunk-SNAPSHOT" convention. Ever since, the bamboo dependency processor errors out with this:

Automatic Maven plan dependencies processing failed: Cannot find parent: com.company.integration:integration-parent for project: null:application-manager-parent:pom:null for project null:application-manager-parent:pom:null

Any tips on how the processor actually links the maven poms to the bamboo builds?

Thanks!


Answers:
author: ArmenA
body: Hi Jonathan,

Thanks for the question. Are you using Maven 3? My suspition is that you are stumbling on [this bug](https://jira.atlassian.com/browse/BAM-9342), which is fixed in Bamboo 4.3. By the way, Bamboo 4.3 will be released next week.

If you are using Maven 2, and the dependency processor still fails for you, please open a ticket on <https://support.atlassian.com> and provide your build logs, Bamboo server logs and screenshots of your Bamboo task configurations.

Cheers,  
Armen

comments: author: Jonathon Roberts
body: Thanks, this was starting to drive me nuts. For now I've disabled the automatic dependency tracking. I'll see if the update works out.


author: Patrick Aikens
body: I'm still running into this in Bamboo 4.4.4, so it certainly wasn't fixed in 4.3.
Error in Bamboo no Plugin with key...task.builder.mvn3' is installed.
Asked by Dirk Bromberg:

Hi,

till the weekend our server has got a bug...

He tells us:

"no Plugin with key 'com.atlassian.bamboo.plugins.maven:task.builder.mvn3' is installed."

and

"no Plugin with key 'com.atlassian.bamboo.plugins.maven:task.builder.mvn2' is installed".

A Restart of the Service does'nt help... The Server had no crash or filesystem errors...

Any idea what we can do to get it back running?

Version is 4.2.1...

Thanks!


Answers:
author: Dirk Bromberg
body: Hm,

the "Atlassian Bamboo Maven Tasks Plugin" was disabled.

After enabeling it works fine.

Don't know how it was disabled...

Thanks!
Is it possible to use sudo to run commands on a stock elastic image?
Asked by Patrick Evans:

I need to install some dependecies before my tests execute and it sure would be nice to be able to do something like:

sudo yum install some_package

I've tried this and of course sudo asks for a password, which I don't have and can't provide. Is there a workaround for this? Everything in the docs points towards doing an EBS volume or a custom AMI, but before I go down that road I thought I would ask.


Answers:
author: Przemek Bruski
body: The simplest approach is to use an instance setup script and either install the dependencies using it or add bamboo user as a paswordless sudoer.

You can edit your instance setup script by clicking edit on image configuration.


Tags: cloud
How can we use Grails 2.1 with Bamboo OnDemand?
Asked by Karsten Silz:

We want to build our Grails application with Bamboo OnDemand using Grails 2.1, but the default Elastic Images only provide Grails 2.0. How do we get Grails 2.1?

![](../../upfiles/Grails_in_Bamboo.png)
\<body\>\</body\>


Answers:
author: Przemek Bruski
body: Use one of these images:

Default Image EBS i386 ami-bf56ead6  
Default Image EBS x86_64 ami-8156eae8  
Default Image S3 i386 ami-9f56eaf6  
Default Image S3 x86_64 ami-8f56eae6

They will be distributed with Bamboo 4.3 and already contain Grails 2.1. You'll need to define the capability manually to /opt/grails-2.1

comments: author: Karsten Silz
body: Thank you! Can I run the "Default Image S3 i386" on a Micro instance?

And how will OnDemand customers find out about updated images in the future?


author: Przemek Bruski
body: You need to use the EBS image on Micro instances.

The stock images are automatically updated on customer instances whenever a new release comes.


Tags: cloud
Bamboo build is jammed
Asked by Asmo Tuomisto:

Hi!

What to do when Bamboos build is jammed?

One build is beeing built about two weeks.


Answers:
author: ArmenA
body: Hi Zacharias,

Thanks for your question. Please try to stop that plan first. If Bamboo cannot stop the plan, then you need to restart Bamboo and see if the problem is reproducible.

In case it happen again, please open a [Support ticket](https://support.atlassian.com) and provide you Bamboo server and remote agent (in case you use one for this plan) [log files](https://confluence.atlassian.com/display/BAMBOO/Logging+in+Bamboo). Also, please describe if the problem is specific to a plan or to a remote agent. What exactly that plan is doing? What kind of Bamboo tasks are used? Is it checking out a lot of data from a repository?

In addition, provide your Bamboo server version and let us know what database system you are using. In case it is HSQL (the embedded one), then I would recommend migrating to an external DB because HSQL is only for evaluation purposes as per [this document](https://confluence.atlassian.com/display/BAMBOO/Supported+platforms), and sometimes can cause strange problems (similar to your case).

Cheers,  
Armen


Tags: build
How come the elastic agent doesn't shut down when idle?
Asked by Karsten Silz:

I configured a Bamboo plan in our OnDemand trial. It runs against a Bitbucket Git repository with the "Default Image S3 i386 (linux) (stock image)" and builds fine. However, neither the Elastic Agent nor the EC2 instance shut down when being idle. In the configuration, the "Elastic Instance Management" was set to "Passive", so the "Idle Agent Shutdown Delay" was 10 minutes. And the "Shutdown Delay" for the EC2 instance was set to 300 (seconds, I guess).

However, the agent was idle for about 20 minutes without doing anything. When I manually requested it to stop, it sat there with a "(Stop requested)" message (or similar) for another couple of minutes. Finally, I terminated the instance manually through Bamboo.

So, how do I get the Elastic Agent and the Elastic Instance to shut down after five minutes of idle time?


Answers:
author: James Dumay
body: Kartsen, the automatic instance management will keep the Elastic Agent running for the whole hour that you have paid for so you get the most value out of your agents.

For example, if an EC2 instance costs 18 cents for an hour and you shut it down after using it for only 20 minutes then start another instance it has costed you 36 cents total.

If the instance has been idle and you approach the full hour you have used Bamboo will shut it down before it costs you another hour.

EDIT: On second thoughts, if it got stuck when you requested it to stop then that sounds like a bug. Best bet is to contact OnDemand support.

comments: author: hughperkins
body: That's not how EC2 works. You get billed on a per-hourly basis, for the maximum number of simulltaneous instances running during that hour. Therefore, if you shut down an instance, and start a new instance, within the space of one hour, you only get billed for one hour-instance.

I would like to be able to get my linux instance to shut down when idle, so that the Windows instance can come online and do the windows build, but currently this isn't possible.


author: Daniel Santos
body: > Each time you start a stopped instance we charge a full instance hour, even if you make this transition multiple times within a single hour.

Reference: [Stop and Start Your Instance - Amazon EC2](http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/Stop_Start.html)


author: hughperkins
body: That's not how EC2 works. You get billed on a per-hourly basis, for the maximum number of simulltaneous instances running during that hour. Therefore, if you shut down an instance, and start a new instance, within the space of one hour, you only get billed for one hour-instance.

I would like to be able to get my linux instance to shut down when idle, so that the Windows instance can come online and do the windows build, but currently this isn't possible.

comments: author: Andreas Kostyrka
body: You are mixing up Google and Amazon. What you described is the way Google tries to minimize your bill. Amazon OTOH, just counts hours, and count non-full hours also as one hour.


Tags: cloud
How can I make the build green, with quarantined test?
Asked by Casey Harford:

We just upgraded to Bamboo 4.2.1 and I have a build which runs a set of Junit tests. One of these tests is failing, so I quarantined it temporarily. I've re-run the build, but in the Dashboard view, it's still showing as red(failing) but the test column says 8 passed. It doesn't show any failures. How can I make the build show green, even with quarantined tests?


Answers:
author: Przemek Bruski
body: It should be green if the only failing test is quarantined ant the build has completed successfully. If it's still red, please open an issue at [support.atlassian.com](http://support.atlassian.com)

comments: author: Casey Harford
body: I'm running the test with maven, and since it's failing in the build log, it's exiting with an error status. I suspect this is why the build is showing red.


author: Casey Harford
body: I ended up finding a work around to my issue. In Bamboo, I use a mvn command to launch tests. I appended \|\| true to the command, which resolves the build color issue.

Example:

mvn clean test \[arguments\] \|\| true


author: Brent Villalobos
body: I have a similar problem. Our build process does both the build and test in a single process. If there is a build or test failure, the process returns a non-zero return code. And so, even if I quarantine failing tests, the job is still recorded as a failure. However, if I added a "\|\| true", then that would pave over all errors, including build errors. That just flips the problem from good builds being marked as failed to bad builds being marked as successful.

Is there a standard or best practice on what a test running should return when there are test failures? One workaround that I can think of is that the build/test process returns a specific code on test failure that a Bamboo wrapper could then check for, return 0, and let the JUnit parser do its thing. Seems hacky to me.


author: bgreen-dt
body: Found this via searching; if anyone's tempted to go down the same path, I suggest doing a testless maven build, then doing a separate maven step that runs the tests which you can \|\| with true.
Bamboo and Bitbucket
Asked by Ivan Laka:

I've tried to configure Bamboo to make builds using Bitbucket as Source repository and MsBuild for builds. Get source task configured successfully but every time i run build it is quequed but never compleated and no errors formed. Searching forums I've found some articles that recommend changing not to use */usr/bin/git* Git Executable. Can you privide some advice?


Answers:
author: Ivan Laka
body: Hi, thank you for your comment. I've done as you said, how should i close this question?


author: LucasA
body: Hello,

The dafaults values of Bamboo configuration may work on most cases. Please raise a support ticket on <http://support.atlassian.com> to get a better support for your case.

Lucas Lima

Atlassian Support


author: SimonS
body: This is something you'd want to run by our support team as well via [https://support.atlassian.com](http://support.atlassian.com)


Tags: cloud
My SEN number does not appear in my Bamboo license key details page
Asked by ehealthwise:

My SEN is SEN-178998 is available under my login for [my.atlassian.com](http://my.atlassian.com) but is not available under my installation of Bamboo \> System \> License Details \> License Key Details page \> Support Entitlement Number (SEN).

Is there a way of entering this information?


Answers:
author: Sultan Maiyaki
body: The SEN can not be added manually as they are only encoded into PAID **version 2 licenses** and since January 2011 evaluation licenses. It appears like your license looks like a v1 license not a v2.


author: Bhushan Nagaraj
body: Not sure but do your server ID's on your [my.atlassian.com](http://my.atlassian.com) and you license key details page match?
Include system variable in global variable
Asked by Rob Gibbens:

Is it possible to create a new global variable which includes a system variable?

For example, I want to create a global variable for MSBuild options that I can use with each of my projects. In this global variable, I want to reference ${bamboo.buildnumber}. When I include the system variable, it does not get evaluated though. It's coming through as -Version "1.0.${bamboo.buildNumber}"

Is there a way to have this evaluated?


Answers:
author: Cameron Ferguson
body: You could potentially just use 2 variables... use the global variable for the first 2 numbers of your version number, and then use the ${bamboo.buildNumber} as the 2nd variable...

so in your scripts or where you pass arguments instead of passing in a single bamboo variable for the version, you can just concat 2 of them together

${bamboo.buildNumberPrefix}.${bamboo.buildNumber}

comments: author: Rob Gibbens
body: That's what I ended up doing, and that worked as I wanted. Thanks.


author: Przemek Bruski
body: What you'd need is nested evaluation of variables, which is not supported atm. You can create an improvement request for it here: [jira.atlassian.com](http://jira.atlassian.com) .


author: Cameron Ferguson
body: I am assuming that you have a build script that is a part of your repositor that you are executing. If you have the ${bamboo.buildNumber} in there, then it will not be resolved.

The ${bamboo.buildNumber} variable will be resolved when you pass it in as an argument to your script when your task executes it, or if you use inline scripting option as a task.

comments: author: Rob Gibbens
body: It's not a script. In Bamboo, I go to Administration-\>Global Variables and add the variable with text "/p:Version=1.0.${bamboo.buildNumber}". Then I go to my Plan-\>Configure Plan-\>Stages-\>Default Job-\>Tasks-\>MSBuild, and enter ${bamboo.myMsBuildOptions} in the Option text box. The string that gets passed to MSBuild includes the variable NAME ${bamboo.buildNumber} , not the variable value. This does NOT get parsed into "1.0.43" like I'd expect.
Merging changes from Mercurial to Subversion during build
Asked by Jan Swaelens:

Hello,

We are playing with the idea to move our trunk svn to a mercurial repository, but we would still like to maintain our subversion trunk branch.

Since there have been quite some changes in the 'automatic merge' functionality of Bamboo I wanted to ask if this would be possible, without too much 'hassle' (read as: additional work).

Could we configure Bamboo to merge the changes made to the mercurial branch to the svn one when a build is made (triggered by a poll of the mercurial branch)?

thanks!


Answers:
author: PiotrA
body: That's quite a challenge there. While I'm certain that Bamboo 'out-of-the-box' doesn't do what you need, I believe the proper solution here would be to plug into your central hg repository with a pre-push hook (or how they are called, you know - the hooks that get triggered whenever a new commit is pushed to your central repository in Mercurial) in such a way, that they will try to commit and sync with your svn repository, and if it fail - reject the hg push. That way the automatic merges from Bamboo won't push successfully if the changeset failed to be committed to the svn repo.

Though, I don't know if there is out-of-the-box solution for transforming arbitrary hg commit into svn commit...


author: Jan Swaelens
body: Ah I see, life is never easy :-).

This makes me want to dump the subversion branch altogether even more...

Thanks for the feedback!


author: Jan Swaelens
body: We don't at the moment, we are exploring our options to see how we can do that -- I was hoping that there was some 'out of the box' solution that might work for us. We are just starting to play with the idea, our main goal is to have the flexibility in DEV of DVCS but (at least for now) keep everything else which is ented on the SVN repo 'as is'.


author: PiotrA
body: Hello Jan,

I'd like to know a little bit more about your use-case, so here is my question: if you do a manual merge in your mercurial branch (manually, without Bamboo), are you able to manually 'merge' it into your svn mirror? How do you do that? With some help from hg-svn bridge/extension?
Can someone reset the migration limit on my account?
Asked by John Lawrence:

I am migrating all of my companies projects from local to cloud-based Bitbucket repositories. Things were going great until I got the following message:

"Your account now has more than 30 repositories created today. Don't worry! You can still create more for free, but in order to prevent Bitbucket misuse, we need to hear from you."

I need to finish this migration today. Can you help?


Answers:
author: Caroline R
body: Hi, [@John Lawrence](/t5/user/viewprofilepage/user-id/4630695)! Welcome to the community!

Just to give you some context, this limit is set to prevent abuse, requiring us to validate if it's an actual person with a real need for that. I went ahead and exempted your workspace, so you should be able to create more than 30 repositories now.

Please let me know how it goes and feel free to share any additional questions or concerns regarding this case.

Kind regards,  
Caroline


Tags: bitbucket-cloud

cloud
Git Import Failed - SSL SYSCALL error: EOF detected
Asked by Christian:

When attempting to import the EpicGames/UnrealEngine repository from Github, after about 30 minutes it fails with the error "SSL SYSCALL error: EOF detected". I believe this may be due to the size and TCP timeout settings on bitbuckets end. How should I go about getting around this so I can successfully import the repository?


Answers:
author: Theodora Boudale
body: Hi [@Christian](/t5/user/viewprofilepage/user-id/4627254) and welcome to the community!

You can do the following instead of importing the repo:

**1.** Take a mirror clone of the GitHub repository

```
git clone --mirror <github_repo_url>
```

**2.** Create a new empty repository in Bitbucket Cloud.  
Please note that when you create a Bitbucket repo from the website, the option **Include .gitignore?** is checked by default, which means the repo won't be empty. You can unselect this option to create an empty repo.

**3.** Push your local mirror clone to the empty Bitbucket repo you created in step 2

```
git push --mirror <bitbucket_repo_url>
```

Please feel free to let me know how it goes and if you need anything further.

Kind regards,  
Theodora


Tags: bitbucket-cloud

cloud

git

import