On Apr 7, 1:30 pm, Marius Mårnes Mathiesen
<[email protected]> wrote:
> On Thu, Apr 7, 2011 at 11:40 AM, moleculezz <[email protected]> wrote:
> > Ok so I am using a different https port to connect to the site, and
> > also when I configured SSH I used a non default port number.
> > When I try to do a git clone, I get the following error:
> > ssh connect to host example.com port 22: Bad file number
> > fatal: the remote end hung up unexpectedly.
>
> > I guess it's trying to use the default port, how can I tell it to use
> > the non default port?
>
> First of all you should try running SSH directly to verify that you're able
> to connect:
>
> $ ssh -p <SSH port> git@<host>

I ran this command and it asks me for a password. But I never set a
password for the git user.
>
> You can add the special settings for a given host into ~/.ssh/config like
> so:
>
> Host <hostname>
>   Port <port>
>
I was able to set the Host and Port to connect. But it still asks me
for a password. I tried to supply the password from my ssh key, but
that didn't work.

> This way SSH will use that port whenever you connect to the given host.
>
> Cheers,
> - Marius

-- 
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]

Reply via email to