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

Branch plans on remote agents

Ari_Mahpour
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
January 10, 2019

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
Daniel Santos
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
January 14, 2019

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
AUG Leaders

Atlassian Community Events