Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Branch plans on remote agents Edited

When Bamboo does a branch build of a project with submodules, it does some sort of merging on the bamboo server (which doesn't have ssh keys setup) and not on the build agent (you can tell by the file path in the error message):

Merge command error: com.atlassian.bamboo.repository.RepositoryException: RES-SESR2-1: Checkout to revision 21e93ae15004006958baf84e4daa43c27434c191 has failed.command ['C:\Program Files\Git\cmd\git.exe' submodule update --init --recursive] failed with code 1. Working directory was [C:\PROD\HOME\xml-data\build-dir\serverSide\RES-SESR2-1\mergeWorkspace]., stderr:
Submodule '*******/src/libs/TerminalCommands' (ssh://git@********:7999/frcm/terminalcommands.git) registered for path '*******/src/libs/TerminalCommands'
Cloning into 'C:/PROD/HOME/xml-data/build-dir/serverSide/RES-SESR2-1/mergeWorkspace/*******/src/libs/TerminalCommands'...
Warning: Permanently added '[********]:7999,[************]:7999' (RSA) to the list of known hosts.
git@***************.com: Permission denied (publickey).
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.
fatal: clone of 'ssh://git@bitbucket.********.com:7999/frcm/terminalcommands.git' into submodule path 'C:/PROD/HOME/xml-data/build-dir/serverSide/RES-SESR2-1/mergeWorkspace/***********/src/libs/TerminalCommands' failed
Failed to clone '*************/src/libs/TerminalCommands'. Retry scheduled

Branch builds without submodules, however, execute entirely on the build agent according to the logs.

How can i get branch builds with submodules to execute only on the build agent?

1 answer

0 votes

Hi @Ari_Mahpour,

Bamboo will not mange the remote agent submodule SSH keys for you, unfortunately. There is an improvement request for this: [BAM-11369] If I want to use git submodules then I shouldn't have to upload and configure SSH keys on each Bamboo Agent.

How can i get branch builds with submodules to execute only on the build agent?

You will need to manually  manage the SSH keys for each of your repository submodules.

Suggest an answer

Log in or Sign up to answer
TAGS
Community showcase
Published in Bamboo

Bamboo 7.1 is here and is packed with value!

I'm happy to announce that Bamboo 7.1 has been released and it’s overflowing with awesome new features. Top-voted issues First and foremost, a bunch of JAC top voted issues has been delivered - y...

621 views 1 6
Read article

Community Events

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

Find an event

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

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you