I can access remote git repository from Bamboo using only one Repository URL
Asked by Build Monkey:

I am trying to get Bamboo to connect with our remote git repository and can only connect by using the following configuration in "Repository URL"

/absolute/path/to/repro/.git

with 'Authentication Type' set to 'None'. In Fisheye, I am able to use

user@server:foo.git

with Authentication type set to None, but I can't do the same in Bamboo. Can someone please help out.

Thanks!


Answers:
author: Tom Towkach
body: I'm able to use this as the URL: <http://localhost:7990/scm/TEST/test.git>

And then I select username/password and I put in admin and the admin password

If I put admin@ I get this duplicate name error, so I just removed it off the URL.


author: Build Monkey
body: I am seeing jgit errors in my logs. We do not have jgit installed and I have specified native git in the server and agent capability. How can this system avoid using jgit.


author: Przemek Bruski
body: make sure *native git capability* is defined on *Bamboo* Server in Administration/Server Capabiliities (and on agents, if you're using remote agents)

comments: author: Build Monkey
body: There are two types of agents, local and remote, correct. I thought locals were running on the same server as bamboo while your remotes run on different servers. Do we need to have remote servers running on remote servers to access the remote repository? Is there documentation for this?   


author: Build Monkey
body: Under Server Capabilities, I see "Git" and that version of git is pointing to /usr/bin/git. I don't see a "native git capability". Do I add this as a custom capability?


author: Build Monkey
body: I verified that the agents as well as the bamboo server are using /usr/bin/git.


author: Build Monkey
body: Are the agents checking out the code? Who are the agents running as? The same owner as the server? I am trying to determine "who" the person is that is accessing the remote repository.


author: Build Monkey
body: I see jgit classes being used. We don't have it installed and native git is defined. How can we stop this from being used:

[at org.shaded.eclipse.jgit.transport.TransportLocal$1.open(TransportLocal.java:130)
at org.shaded.eclipse.jgit.transport.TransportBundleFile$1.open(TransportBundleFile.java:105)
at org.shaded.eclipse.jgit.transport.Transport.open(Transport.java:546)
at org.shaded.eclipse.jgit.transport.Transport.open(Transport.java:517)
at com.a](i-can-access-remote-git-repository-from-bamboo-using-only-one-repository-url)


author: Build Monkey
body: After reading other peoples' issue, I noticed that bamboo does use jgit for some operations. I installed org.eclipse.jgit-1.3.0.jar in WEB-INF/lib, and restarted the server, but still getting the same error. Any suggestions? Thanks


author: Build Monkey
body: More information:

I created a script that was able to clone the repository so the agent is not being denied access to the remote repository.


author: Build Monkey
body: More information from the log file

Caused by: com.jcraft.jsch.JSchException: Auth fail  
at com.jcraft.jsch.Session.connect(Session.java:484)  
at org.shaded.eclipse.jgit.transport.JschConfigSessionFactory.getSession(JschConfigSessionFactory.java:128)  
... 245 more

I want to see the 245 more errors since this isn't giving me any feedback.

I have set the Auth Type to 'None'.


author: Build Monkey
body: More data. I am seeing this on startup and not sure if it is related to not being able to lo into git. At this point I am grasping and will shortly throw my hands up. I am currently evaluating the product for purchase and we won't be able to go any further if this isn't resolved.

2012-06-19 16:00:43,860 WARN \[main\] \[EhCacheProvider\] Could not find configuration \[bucket.user.propertyset.BucketPropertySetItem\]; using defaults.  
2012-06-19 16:00:46,049 WARN \[main\] \[EhCacheProvider\] Could not find configuration \[net.sf.hibernate.cache.UpdateTimestampsCache\]; using defaults.  
2012-06-19 16:00:46,053 WARN \[main\] \[EhCacheProvider\] Could not find configuration \[net.sf.hibernate.cache.StandardQueryCache\]; using defaults.  
2012-06-19 16:00:51,547 WARN \[main\] \[CustomType\] custom type does not implement Serializable: class com.atlassian.bamboo.security.acegi.acls.HibernateSidUserType  
2012-06-19 16:00:51,560 WARN \[main\] \[CustomType\] custom type does not implement Serializable: class com.atlassian.bamboo.security.acegi.acls.HibernateSidUserType  
2012-06-19 16:00:51,560 WARN \[main\] \[CustomType\] custom type does not implement Serializable: class com.atlassian.bamboo.security.acegi.acls.HibernatePermissionUserType


author: Przemek Bruski
body: The warnings are unrelated to your problem. I think it's best if you contacted support at [support.atlassian.com](http://support.atlassian.com)


author: Przemek Bruski
body: Does user@server:/\~/foo.git work?

comments: author: Przemek Bruski
body: Are you using native git in Bamboo?


author: Build Monkey
body: No. getting the same RepositoryException error.

Again, I have the same set up (user@server:foo.git) in Fisheye and am having no problems. Both Fisheye and Bamboo are running as the same user on the same machine.


author: Build Monkey
body: What do you mean "native git"? git comes with Bamboo? Like Fisheye, it might be using the server version in /usr/bin/git and it's version 1.7.1


author: Build Monkey
body: The error I am getting when using

user@server:foo.git is

Error encountered while triggering manual build: com.atlassian.bamboo.repository.RepositoryException: user@server:foo.git: Auth fail

Plan 'TEST' did not start


Tags: git