youngmon/atlassian-qna huggingface dataset:
Can I run a deployment regardless of tests, and a second deployment only if all tests pass?
Asked by Matt Summers:

I'm setting up our continuous deployment for the first time and I'm a little stuck. Any pointers would be hugely appreciated.

We have two internal test servers; let's called them Test01 and Test02. I've set up a build plan that pulls from the Git repository, builds the projects, and then a linked deployment project that deploys to Test01.

What I really need is for the build artifact to always be deployed to Test01, and for it also to be deployed to Test02, but only if all tests pass.

Any idea how I could set that up? Seeing as it's a separate deployment, I'm guessing I need a separate build plan that takes the artifact from the first one and runs the unit tests? But how can I trigger one build plan from the completion of another? Can I choose to run a deployment based whether or not unit tests passed?

I've just had another look at the existing build plan and did a quick test by checking in a failed unit test. This inherently prevents the deployment, which is a problem for Test01, where we want to be able to see the deployed build regardless of tests.

Am I going to have to ignore the official deployment functionality and add my own tasks to the build plans to achieve the same result via msdeploy? I could do this in the Finally section for the Test01 deploy. Maybe that'll be easier? I guess I'm also going to have to add the Test02 tasks into the same build plan as well? Feels a bit messy..

**EDIT**

I think I've worked it out. Should be fine if I follow these stages:

1. Get latest from git repository and save to artifact.
2. Take artifact and build it. If it doesn't build, the build fails.
3. Deploy to Test01.
4. Run unit tests, which could fail the build.
5. Triggered Deployment --\> Deploy to Test02 when all is well.

I also have database upgrades to consider, but I should be able to factor these in as well. If building the upgrade script fails, then it all fails, otherwise I'll apply upgrades at the same time as doing the deployments.

I have no karma points, so feel free to post this as the answer so that I can mark it as the answer!


Answers:
author: VikasB
body: You can use Cucumber For Bamboo plugin. This plugin adds Cucumber parsers in Build as well ad Deployment plans. It provides options to pass or fail build if any test is failed or based on failure threshold or can just print test results in Log without affecting deployment status.  
The plugin also adds new UI elements to display deployment tests, Cucumbers results and pie chart of tests. It also has features to automatically link tests with JIRA issues.  
<https://marketplace.atlassian.com/plugins/com.mdb.plugins.cucumberforbamboo/server/overview>


Tags: bamboo-administration
Find or lookup cards in other boards based on a custom field value
Asked by Gary Liddington:

To give context -   

if I have a board, with a card, with a customfield called 'Deal Ref' and a value of 101, I want to be able to search for that value of 101 in another board and link the cards.  

I could do this if the value was embedded in the cards title, but I want to do it at the custom field level, preferably looking for the value in a known custom field on another board.  

I cannot find a way to do this.. Anyone think they can?  


Answers:
author: Silvia
body: Hi [@Gary Liddington](/t5/user/viewprofilepage/user-id/4989010)

In Blue Cat Reports you can create a Quick List and apply filters based on the custom fields you have across all/selected boards. From there, you can automate this report to be sent to your email on a daily basis.

The number filter looks like this

![filter.PNG](https://community.atlassian.com/t5/image/serverpage/image-id/232713i5D7BA2971A2A88E4/image-dimensions/310x231?v=v2 "filter.PNG")

This would enable you to see which cards match and then link them up.

When you sign up for a trial with us at [Blue Cat](https://trello.com/power-ups/5d9c90aa18965066fcd44730/reports-by-blue-cat), you can reach out to our support through the app and we are happy to help with creating a report as the above or anything else you might need.

comments: author: Gary Liddington
body: Thanks - it's unlikely that we can use your app but appreciate you reaching out.


author: milynnus
body: [@Gary Liddington](/t5/user/viewprofilepage/user-id/4989010)

You can do it via api but it will take a fair bit of resources. It is likely that you get a 'time-out' from Trello especially there are many cards to inspect.

But if you want to lookup the value on a specific card then you can checkout this to see if it fit your purpose

<https://dojo.hipposites.com/space-butler/shared-card-detail/13f6cfd0745b4e2dbf2a6e5544a42234-shared-card-detail>

comments: author: Gary Liddington
body: Hi and thanks.. Yes, I can't really see being able to do this other than API. Unfortunately we have quite a rigorous app/power-up acceptance process (mainly around understanding the security of where data manipulated in Trello is stored at any given point).  

Thanks for reaching out though.


author: milynnus
body: [@Gary Liddington](/t5/user/viewprofilepage/user-id/4989010)

Apps on Deta Space runs on your personal cloud including the apps data including your credentials.

Yes, I would be equally careful about sharing my api key and token.
How do you control default agents on a buildserver?
Asked by Johan Ferner:

Hi,

Is there a way to configure Bamboo to these requirements:

* I want to limit the number of local agents that are available by default if you don't add any additional capabilities.
* I want to allow additional local agents that are configured using additional capabilities
* I want to allow remote agents only for builds that specify additional capabilities.

My situation right now is that the builds that don't specify capabilities use everyone elses agents (including remote agents). So I want to limit this.


Answers:
author: Daniel Wester
body: Not out of the box... You might want to take a look at <https://marketplace.atlassian.com/plugins/com.edwardawebb.bamboo-group-agent> though... (Haven't used it )

comments: author: Johan Ferner
body: Thanks for answering. [](https://eddiewebb.atlassian.net/browse/BGA-4)<https://eddiewebb.atlassian.net/browse/BGA-4>and [](https://eddiewebb.atlassian.net/browse/BGA-6)<https://eddiewebb.atlassian.net/browse/BGA-6>indicates problems with newer versions. I will keep looking.


Tags: bamboo-administration
Bamboo server load and recommendation for tuning
Asked by Sysop Team:

Hi,

we have a Bamboo server (version 5.0 build 3715) on a DELL server (Quadcore Intel(R) Xeon(R) CPU X3450 @ 2.67GHz, 16 GB RAM, 2 x 2 TB harddisk (RAID)) and now we have from time to time really heavy load on the machine. Therefore I want to ask if someone can help us to tune the machine. The current setup for the JVM opts is: -Xms256m -Xmx8192m -XX:MaxPermSize=256m. I changed this now to: -Xms5120m -Xmx6144m -XX:MaxPermSize=256m \<- makes this sense? We have 7 local agents and 10 EC2 remote agents running, 46 build plans, and around 7 different branches for some of the plans. Where to look for bottlenecks?


Answers:
author: Sysop Team
body: Thanks for your quick response. We'll try what you suggested.


author: Jan Swaelens
body: Hello,

You should start by installing the JavaMelody plugin for Bamboo. This will give you nice stats about how much memory is actually used by the Bamboo instance.

In ou setup the bamboo JVM never takes more than 2GB, whereas the threads that are spawned from the builds itself consume additional memory because they are launched in separate JVM's (depends on how your builds are actually setup ofcourse).

Note that JavaMelody will only give you information about the JVM of the Bamboo instance, it can be handy to also monitor the machine with something like Zabbix (or alternatives) to make sure that spawned processes don't overload the machine either.

cheers


Tags: bamboo-administration
bamboo cant start after installation on windows server
Asked by yuval grossman:

after installing bamboo, when executing the startBamboo.bat file i get a message says :

More help is available by typing NET HELPMSG 2185.

when trying to reach the bamboo bia browser http:localhost:8085 i get nothing.

please advice

thank you

Yuval.


Answers:
author: ssetayeshfar
body: Hello Yuval,

What version of Bamboo do you have installed? if version 5.1 or newer, please make sure to use the \*.bat file located under bin directory:

\<bamboo-installation-directory\>\\bin\\start-bamboo.bat

Please right click and run as administrator if the problem persists.

You can also use the "BambooConsole.bat" file.

If you continue receiving the error and still can't access Bamboo at: "http://localhost:8085", please open a ticket in our support site "https://support.atlassian.com" and attach your Bamboo log files from under \<bamboo-home\>/logs to the ticket.

Hope this helps!

Best,

Sepideh


Tags: startup
Linking Jira user repository to Bamboo 5.2
Asked by Aaron Cunnington:

Hello,

I am having difficulty linking our Bamboo 5.2 installation with our Jira 6.1.1 installation. I am being asked for an application name and application password, both of which I do not know.

I am an administrator on both installations so if someone could provide me with a solution, it would be much appreciated.

Many thanks, Aaron.


Answers:
author: Aaron Cunnington
body: Thanks, we found there was a mismatch of IP addresses on the Jira administrator interface, in the Jira User Server section. We fixed this and it worked.


author: Peter Van de Voorde
body: Hi Aaron,

You should be able to simply use your own username and password (if you are an admin user).

Other wise you'll need to create a user in Jira specifically for Bamboo to use when connecting to Jira and vice-versa.

Best regards,

Peter

comments: author: Aaron Cunnington
body: Hi Peter,

Thanks for your reply. However when I try to use my Jira login (or a service account I created in Jira) I get the following error:

Failed to change the active user repository: com.atlassian.crowd.exception.InvalidAuthenticationException: Application failed to authenticate


author: Peter Van de Voorde
body: Hi Aaron,

Take a look at this answer : it might help you.

[https://answers.atlassian.com/questions/81746/why-does-bamboo-throw-an-exception-when-attempting-to-configure-use-of-jira-user-repository](/questions/81746/why-does-bamboo-throw-an-exception-when-attempting-to-configure-use-of-jira-user-repository)

Best regards,  
Peter


Tags: bamboo-administration
How does Bamboo calculate build times?
Asked by Dan Rumney:

When I look at my build times, they do not seem to tally with the time difference between the first and last items in my logs.

Where is this additional time being spent? Is there any way to find out? Is this including queue time as well as execute time?


Answers:
author: Felipe Kraemer
body: Hi Dan,

Could it be a case that you had a hung build before now? The build duration is estimated based on heuritistics of previous builds, and it also takes into account queue wait time while the average time for a job within in a plan does not.

comments: author: Dan Rumney
body: I don't think hung builds is an issue, but the fact that build duration takes queuing into account wasn't clear to me. My build times make sense now :)
How to integrate Bamboo with Enterprise GitHub?
Asked by John Tangney:

We're evaluating Bamboo for our CD pipelines. We use GitHub Enterprise, and we branch each release. I know that Bamboo works with [GitHub.com](http://GitHub.com), but how do I set it up to work with Enterprise GitHub (same thing, but locally hosted)? Also, how do triggers work? And are branch builds correctly triggered?


Answers:
author: Krystian Brazulewicz
body: See here for configuring custom URL for GitHub repository: <https://answers.atlassian.com/questions/14212105>


author: Hiren Adesara
body: I know that bamboo do not officially support github enterprise. Is there a work around, if so what is it?


author: benson margulies
body: I've got this all working for manually configured branches. We just created a shared credential and all is well. I just now configured automatic branches, and I haven't seen one get detected yet.


Tags: bamboo-administration

enterprise

github

integration
Bamboo, RPMs, Deploy Pipelines, oh my.
Asked by dustin_barnes:

So I've got Bamboo up and running on my project, and I've got it doing "releases" into Artifactory.

I really want Bamboo to manage the deployment pipeline as well, but there are a couple things I'm not clear on. First, our configuration management team uses RPMs as the unit of deployment. I know I could build an RPM and pass that along as an artifact, but then it doesn't go into Koji.

Here's what I really want (this is a non-java but totally mavenized project), somebody tell me if it's crazy:

1. Check out, compile, test project. Install snapshot into artifactory (working fine)
2. If (1) succeeds, perform a release build. Update version, package as tgz, tag source repo, install into Artifactory (working fine)
3. (Separate plan) Get file from Artifactory, create RPM, install RPM in Koji repo (Understand how to do this with scripts or whatever)
4. Deploy pipeline deals with the RPM (Not sure how to do this)

Can somebody point me in the right direction with this one? Do we have to give up RPMs to use the deployment part of the tool?


Answers:
author: jeff mease
body: I did this by scripting the pull from artifactory using cURL to get the artifact. Then a ssh script to the target from a bamboo script task that runs a yum install of the rpm .

We later modified it to run a CHEF script for the install and pulled everything out of the pipeline except a release promotion of the rpm to another yum repo in artifactory.
SSH task Hanging or Disconnecting before completion
Asked by Stephen Goldberg:

I have an SSH task I use after Bamboo deploys Maven .war onto my server, I have used many variations of the following:

sudo nohup service jboss stop \&  
echo "SLEEPING for 5 seconds during Shutdown of Jboss"  
sleep 5  
./DeployPrep.sh  
sudo rm -f /usr/share/jboss-as/standalone/deployments/ROOT.war.deployed /usr/share/jboss-as/standalone/deployments/ROOT.war   
sudo mv /home/bamboo/ROOT.war /usr/share/jboss-as/standalone/deployments/  
sudo nohup service jboss start \&  
echo "\*\*\*\*\*SLEEP while JBoss starts: 75 seconds\*\*\*\*\*\*"  
sleep 75  
sudo mv /home/bamboo/\*.war ../  
cd ../  
exit

I have also tried exit = 0,

Everything seems to work okay all the way up to starting the server.

Either does not start jboss server and disconnects succesfully or starts the server and does not disconnect?

Any suggestions about how to make the SSH task disconnect after waiting for Jboss to start?

Thank you for your time and diligence.

Cheers!


Answers:
author: Stephen Goldberg
body: I have found a resolution..

I tested that both having a SSH task run a script or putting it in the Script task will not hang bamboo.

/sbin/service jboss restart \> /tmp/stderrlogdump 2\>\&1 \&

Apparently dumping stderr releases the terminal from waiting for the process and/or its children to finish.

Thumbs UP!

<br />

comments: author: ThiagoBomfim
body: Also worth checking <https://answers.atlassian.com/questions/69939/bamboo-waits-for-script-task-to-terminate-although-it-is-run-in-the-background>


author: Stephen Goldberg
body: Sorry friend, I have no good news. I'll keep experimenting, please let me know if you find a solution as well.


author: Benoit Sarrazin
body: I have a similar problem.

The SSH task never "completes" and just hangs. So my next tasks are never executed.  
Were you able to fix your problem?


Tags: cloud
What variable is the commit message
Asked by Brett Nottingham:

After a build completes from a git repo, there is a code commit message value in the build result summary. This is just the commit message in the git commit/push. I want to pass that value to a script, but I don't see in the global variable list which variable to use. Anyone know what specifically it is?


Answers:
author: Marcin Gardias
body: Commit message is not available as a variable, only commit sha is:

```
${bamboo.planRepository.revision}
```

You can extract commit message with git like this:

```
git log -1 --format=%s%n%b
```
Is there a way to force certain jobs to go to a specific group of agents?
Asked by Ingram Smarius:

Perhaps the question is not very clear, but let's say I have 5 agents, is there a way to make sure that all my "QA" builds which can be more time consuming go to only Agent 1 \& 2?

Thanks


Answers:
author: Ingram Smarius
body: Waiting for the plugin to be available or when Bamboo implements it as a feature.


author: Przemek Bruski
body: add a capability qa_build to these agents and make your jobs require that capability.

comments: author: Ingram Smarius
body: Hi Przemek, thanks for replying.  
I only used QA as an example but in reality it's a bit more complex than that, we are dealing with hundreds of builds in a very large number of projects, so going in each job is just too much at this point.

It's much easier to implement what you are suggesting when you are just starting up.

I think I found what I was looking for here: <https://marketplace.atlassian.com/plugins/com.edwardawebb.bamboo-group-agent>

Unfortunately this is not available for 5.0.1
catalina.out file in Bamboo 5.2
Asked by roy_lyons:

-rw-rw-r--. 1 bamboocit devcit 502 Dec 5 08:15 catalina.2013-12-05.log  
-rw-rw-r--. 1 bamboocit devcit 15845 Dec 5 13:33 localhost.2013-12-05.log  
-rw-rw-r--. 1 bamboocit devcit 54736154 Dec 5 14:52 access_log.2013-12-05  
-rw-rw-r--. 1 bamboocit devcit 22404170373 Dec 5 14:52 catalina.out

That catalina.out file is 22 gigs all on its own.

So if it is creating separate catalina.{datestamp}.log files why is it still outputting to catalina.out?


Answers:
author: Jan Swaelens
body: You can adapt the logging configuration in conf/logging.properties, this is happending because next to the rolling appender the standard out is enabled too.

Simply remove the 'ConsoleHandler' from the handler properties to get rid of this file.

comments: author: jvelapol
body: Is this a good answer, though? Is the standard out not helpful? Or is it something that should be enabled only at certain times?
Do remote agents count based on "concurrently active" or as "total in the system"?
Asked by Kai Servay:

In regards to Bamboo licensing i was wondering if i have a single remote agent, can that be a different agent for different builds? e.g. if i need windows and linux builds can they be done with a single agent license with only one of two agents beeing active at a time?


Answers:
author: Przemek Bruski
body: The licence is for total number. To achieve what you want you'd need to shut down one of the agents.

comments: author: Kai Servay
body: Thank you very much and sorry for the delayed reply!
Custom Agent Instance AMI in Sydney region
Asked by Jonathan Eagle:

I'm trying to set up Bamboo and want to have it run instances based in the AWS Sydney region (which is where our application environment is based).

I have a custom AMI prepared in Sydney, but when I try to add it via Bamboo instance configuration and error is returned saying that it cannot be found.

![](../../upfiles/Setting_up_AMI_in_Sydney_-_Bamboo.png)

![](../../upfiles/Setting_up_AMI_in_Sydney_-_AWS.png)

The Bamboo JIRA ticket [BAM-9515](https://jira.atlassian.com/browse/BAM-9515) suggests that this should not be a problem.

Currently I am only able to run Bamboo OnDemand in US-East. Please help to shed some light on the issue.

Thanks,

Jonathan


Answers:
author: Jonathan Eagle
body: Found that the region could be configured back in the Bamboo Elastic Configuration page. I thought this was already set to Sydney as that's what I selected during set up, but when I went back to this page I saw it to be set to US East.

A clearer or more detailed error message here would be appreciated, but otherwise it works as expected.


Tags: cloud
Where to find plan log in Bamboo 5?
Asked by Yeou-Fang Wang:

In the Bamboo 3, one can navigate to a Plan's "Plan Configuration" summary page, and at the bottom, click on a "View Plan Log" link to see the plan log to see what evaluations occurred, and what triggered the build.

It looks like this feature is present on the Bamboo 5: [https://server:port/chain/viewChainActivityLog.action?planKey=DEVBLD](https://scae-bamboo.jpl.nasa.gov:8443/chain/viewChainActivityLog.action?planKey=SMAP-DEVBLD)  
..but I can't figure out how to get to it via a link... Is there a way to get to the link?


Answers:
author: Yeou-Fang Wang
body: According to Atlassian support, plan log link has been removed.
Exclude specific build(s) from estimate
Asked by Matt G:

We have several build plans which first need to check out a significant amount of code via an SVN checkout stage, and that typically takes between 1-2 hours. Each subsequent plan execution takes significantly less time than that, however the build time estimates are skewed until about 30-40 builds later. Occasionally, a full-checkout is necessary, and the estimates are thrown off again.

Is there a way to have Bamboo exclude outliers or otherwise manually exclude longer builds from its estimated time to completion? Even on a per-stage basis that would be useful.


Answers:
author: Gretchen
body: Remove the result. Of course then you lose the duration on your outliers.


Tags: bamboo-administration
Anyone know why I'm getting a 404 error when Visual Studio connector loads Bamboo build logs?
Asked by Matt Summers:

I've install the Visual Studio connector and it all works great, apart from one thing. When I open up the results of a Bamboo build, it shows that it failed to load the build logs from the server, and this is caused by a 404 (not found).

Any ideas?

Here's the full exception:

```
The remote server returned an error: (404) Not Found.System.Net.WebException   at System.Net.HttpWebRequest.GetResponse()   at Atlassian.plvs.api.bamboo.rest.RestSession.getQueryResultStream(String endpoint, Boolean setBasicAuth)   at Atlassian.plvs.api.bamboo.rest.RestSession.getBuildLog(String logUrl)   at Atlassian.plvs.api.bamboo.BambooServerFacade.&lt;&gt;c__DisplayClass1c.&lt;getBuildLog&gt;b__1b()   at Atlassian.plvs.api.bamboo.BambooServerFacade.wrapExceptions[T](RestSession session, Wrapped`1 wrapped)   at Atlassian.plvs.api.bamboo.BambooServerFacade.getBuildLog(BambooServer server, String logUrl)   at Atlassian.plvs.ui.bamboo.BuildDetailsPanel.getLogRunner()
```


Answers:
author: Michael Haas
body: Hi everyone!

The same exception is shown on my local test setup as well.

Environment:

\* Windows 7 64-bit

\* Kaspersky Endpoint Security 8

\* Bamboo version 5.3 build 4101

\* Other tomcat instances are running but on different ports

\* Bamboo ports are 7007 (shutdown) and 7085 (connector)

The file is available in .../xml-data/builds/\[JOB\]-\[JOB\]-JOB1/download-data/build-logs/

Should it be somewhere else? Would it help to create a script task in the build job to copy the log file anywhere else?

Or are there any other solutions or workarounds already?


Tags: bamboo-administration

connector

visual-studio