Run job on remote agent, but only for a specific branch

Hi all.

We have an iOS app project. For production releases we still have to build the app using iPhone SDK 6.0, that means we have to stick with Xcode 4 for a while.

So there's a Bamboo CI running on OSX 10.8 with Xcode 4 installed.
There's a plan that points to GitHub repo, picks up and builds the app, and it is set up to detect branches automatically.

Then we also start wroking on iOS 7 support and there's a separate branch for that (say merge-branch) in GitHub. However, for this branch Xcode 5 is used by developers, and there's a known problem - Interface Builder files are not backwards compatible. If an IB file is saved in Xcode 5, then Xcode 4 will fail to compile it. That means we have to build merge-branch using Xcode 5.

For that purpose I setup another Mac running OSX 10.9 with Xcode 5 installed; and I run a remote agent on that machine.

I know I could have 2 Xcodes installed on one machine then switch between environments, but that isn't really an easy task, afaik.

Now what I want to do is

  • To build master branch on Bamboo server machine (Xcode 4) using one of the local agents
  • To build merge-branch on remote agent (using Xcode 5)

The original plan is split in stages and jobs, like this

  • Build Stage
    • Build Job
  • Resign App Stage
    • Resign Job
  • Publish Build Results Stage
    • Publish Build Results Job
  • Update JIRA Stage
    • Update JIRA Job

So I want to run all the jobs for all branches using local agents, except Build Job for merge-branch, in this case I want to run the job on Remote Agent.

I know I could use custom agent capabilities to delegate the job to a specific agent, but this solution will build all branches on remote agent.

That means I want to configure required job capabilities differently for each branch, and that looks like somethign not possible yet.

What would be the best workaround so far?

I'm thinking to duplicate the whole plan and point it to the specific branch in repo, that in this new plan modify the build job and require custom capability to be sure it's always executed on remote agent; or even configure an agent as dedicated agent for this particular job.

1 answer

This widget could not be displayed.

This is a very good question. I too would like to dedicate a Bamboo agent to a branch of a build plan.

Suggest an answer

Log in or Sign up to answer
Community showcase
Posted Tuesday in Jira

What modern development practices are at the heart of how your team delivers software?

Hey Community mates! Claire here from the Software Product Marketing team. We all know software development changes rapidly, and it's often tough to keep up. But from our research, we've found the h...

95 views 1 2
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you