Bamboo
  1. Bamboo
  2. BAM-11096

Bamboo Git Plugin (native mode) shouldn't hang when using ssh protocol on windows.

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 3.4.3
    • Fix Version/s: 4.1.2, 4.2
    • Component/s: Repository (Git)
    • Labels:
    • Streams:
      Poland
    • Last commented by user?:
      true
    • Story Points:
      3
    • Comments:
      35
    • Internal Priority:
      1. Highest

      Description

      Steps to reproduce:
      1) grab a windows machine
      2) install there minimal git: http://code.google.com/p/msysgit/
      3) grab Bamboo 3.4.3 (I think this error will still occur on newer versions too)
      4) set up a Plan that uses Git as repository and uses ssh:// protocol, for example:
      4.1) url = ssh://git@github.com/atlassian/bamboo-git-plugin.git
      (use SSH keyfile as "authentication type" - set up your github account accordingly)
      5) use the windows machine from point (1) as a remote agent, connect to bamboo
      6) in bamboo administration - set up the remote agent to use Git capability (so it will use native-git checkout instead of jgit checkout)
      7) run the plan
      8a) observed behavior is that the build hangs at code checkout (possibly to localhost proxy-SSH fingerprint host key checking)
      8b) while expected behavior is that the build will... build.

      from: BSP-6565
      and: https://answers.atlassian.com/questions/39371/ssh-port-on-git-repository-polling

        Issue Links

          Activity

          Hide
          Ron Chan added a comment -

          By the way, we're on Bamboo 4.4.4

          Show
          Ron Chan added a comment - By the way, we're on Bamboo 4.4.4
          Hide
          HomeAway added a comment -

          Ron:

          1) Make sure the service account that bamboo is running on the agent as has a ~\.ssh\config file that has this in it:
          Host [yourgithost]
          NoHostAuthenticationForLocalhost yes
          User [serviceusername]
          Hostname [yourgithost]
          IdentityFile ~/.ssh/id_rsa <--that is the default name the ssh-keygen gives if you don't specify one
          Port 7999 <--that's stash's default, yours could be 223 or whatever

          2) Make sure you have the private ssh key in the above, not the .pub

          3) Make sure you register the public (.pub) ssh key for the service account in Stash or github (whatever DVCS you're using)

          4) Make sure your Source Repository's ssh key setting in the plan in Bamboo is loaded with the private key.

          Show
          HomeAway added a comment - Ron: 1) Make sure the service account that bamboo is running on the agent as has a ~\.ssh\config file that has this in it: Host [yourgithost] NoHostAuthenticationForLocalhost yes User [serviceusername] Hostname [yourgithost] IdentityFile ~/.ssh/id_rsa <--that is the default name the ssh-keygen gives if you don't specify one Port 7999 <--that's stash's default, yours could be 223 or whatever 2) Make sure you have the private ssh key in the above, not the .pub 3) Make sure you register the public (.pub) ssh key for the service account in Stash or github (whatever DVCS you're using) 4) Make sure your Source Repository's ssh key setting in the plan in Bamboo is loaded with the private key.
          Hide
          HomeAway added a comment -

          Also, that ~\.ssh\config must be on the agent. If its windows7 its C:\users[username]\.ssh (you might have to create the .ssh folder)

          Show
          HomeAway added a comment - Also, that ~\.ssh\config must be on the agent. If its windows7 its C:\users[username]\.ssh (you might have to create the .ssh folder)
          Hide
          Ron Chan added a comment -

          Thanks for the suggestion HomeAway.

          However, I went through your steps and my results are the same. I'm assuming this is supposed to address the issue of building the "submodules". Any other suggestions or should there be additional steps that i'm missing?

          Please help.

          Show
          Ron Chan added a comment - Thanks for the suggestion HomeAway. However, I went through your steps and my results are the same. I'm assuming this is supposed to address the issue of building the "submodules". Any other suggestions or should there be additional steps that i'm missing? Please help.
          Hide
          HomeAway added a comment -

          Sorry, Ron. I just posted what I wish someone else had when I was pulling my hair out way back!
          If your public key is being denied its an ssh thing. Try the http creds if you can to eliminate/identify that as the problem.

          Show
          HomeAway added a comment - Sorry, Ron. I just posted what I wish someone else had when I was pulling my hair out way back! If your public key is being denied its an ssh thing. Try the http creds if you can to eliminate/identify that as the problem.

            People

            • Votes:
              2 Vote for this issue
              Watchers:
              16 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Last commented:
                48 weeks, 3 days ago