I'm trying to start using Redhat OpenShift with a JBoss 7 Server Cartridge, but as I'm trying to do a git clone I get:
$ git clone ssh://username_from_openshift@application_name-host_name.rhcloud.com/~/git/application_name.git/ /development/repos/openshift/
Initialized empty Git repository in /development/repos/openshift/.git/
ssh: connect to host application_name-host_name.rhcloud.com port 22: Connection refused
fatal: The remote end hung up unexpectedly
Now I am doing this in a company and I am using it's proxy to access the internet on this machine. I'm running Linux CentOS release 6.5 (Final).
I tried adding a "config" file with the following contents in ~/.ssh/:
Host application_name-host_name.rhcloud.com
ProxyCommand nc -X connect -x my_company_proxy.com:8080 %h %p
ServerAliveInterval 10
Then I got this message while trying to perform a git clone command:
$ git clone ssh://username_from_openshift@application_name-host_name.rhcloud.com/~/git/application_name.git/ /development/repos/openshift/
Initialized empty Git repository in /development/repos/openshift/.git/
nc: Proxy error: "HTTP/1.0 403 Forbidden"
ssh_exchange_identification: Connection closed by remote host
fatal: The remote end hung up unexpectedly
if I try connecting directly via ssh, I get error messages in a similar fashion.
Without that config file:
$ ssh username_from_openshift@application_name-host_name.rhcloud.com
ssh: connect to host application_name-host_name.rhcloud.com port 22: Connection refused
With the config file:
$ ssh username_from_openshift@application_name-host_name.rhcloud.com
nc: Proxy error: "HTTP/1.0 403 Forbidden"
ssh_exchange_identification: Connection closed by remote host
I also tried using rhc setup (OpenShift client tools for connecting and it shows the number of gears I have, but it still gives similar error messages.
Without the config file:
An SSH connection could not be established to application_name-host_name.rhcloud.com. Your
SSH configuration may not be correct, or the application may not be responding.
Connection refused - connect(2) (Errno::ECONNREFUSED)
With the config file:
An SSH connection could not be established to application_name-host_name.rhcloud.com. Your
SSH configuration may not be correct, or the application may not be responding.
connection closed by remote host (Net::SSH::Disconnect)
Now I also had generated my ssh public key on my machine and pasted it in OpenShift Settings under "Public Keys", so I guess that shouldn't be the problem.
Well? Any ideas and suggestions? Thanks