Details
-
Bug
-
Resolution: Invalid
-
Medium
Description
I have internal bitbucket and whenever I try to generate a clone link for ssh it is created wrong:
This is the link that gets generated:
ssh://git@192.168.5.15:7999/aut/az_terraform.git
Which doesn't work and I get this error:
[jenkins@jenkins1 test]$ git clone ssh://git@192.168.5.15:7999/aut/az_terraform.git
Cloning into 'az_terraform'...
ssh: connect to host 192.168.5.15 port 7999: No route to host
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
Even though the repo is public.
I can only clone and push via http which is:
http://jenkins@192.168.5.15:7990/scm/aut/az_terraform.git
This is what happens when I try to test my ssh connection to my internal bitbucket with my service user:
#!bash [jenkins@jenkins1 az_terraform]$ ssh -T -v -i ~/.ssh/bitbucketinternal jenkins@192.168.5.15 OpenSSH_6.6.1, OpenSSL 1.0.1e-fips 11 Feb 2013 debug1: Reading configuration data /home/jenkins/.ssh/config debug1: /home/jenkins/.ssh/config line 1: Applying options for 192.168.5.15 debug1: Reading configuration data /etc/ssh/ssh_config debug1: /etc/ssh/ssh_config line 55: Applying options for * debug1: Connecting to 192.168.5.15 [192.168.5.15] port 7990. debug1: Connection established. debug1: identity file /home/jenkins/.ssh/bitbucketinternal type 1 debug1: identity file /home/jenkins/.ssh/bitbucketinternal-cert type -1 debug1: identity file /home/jenkins/.ssh/bitbucketinternal type 1 debug1: identity file /home/jenkins/.ssh/bitbucketinternal-cert type -1 debug1: Enabling compatibility mode for protocol 2.0 debug1: Local version string SSH-2.0-OpenSSH_6.6.1 debug1: ssh_exchange_identification: HTTP/1.1 400 Bad Request debug1: ssh_exchange_identification: Server: Apache-Coyote/1.1 debug1: ssh_exchange_identification: Transfer-Encoding: chunked debug1: ssh_exchange_identification: Date: Mon, 18 Jul 2016 21:57:59 GMT debug1: ssh_exchange_identification: Connection: close debug1: ssh_exchange_identification: debug1: ssh_exchange_identification: 0 debug1: ssh_exchange_identification: ssh_exchange_identification: Connection closed by remote host
If I try to push, I immediately get a password prompt for my jenkins user. The jenkins user has a valid key, it's uploaded to bitbucket, it's loaded on the source machine. I'm using the latest bitbucket version.