Use git on hostgator hosting in ssh via public / private key

0

I am trying to access my hosting through the public and private key system but it is giving error when I create the config file to access it without password

I created the key in gitbash through the command "ssh-keygen" and copied / pasted in the cpanel area to import a public key and authorized it; I created the config file with this structure:

Host rafael

HostName -ip from my hosting -

Port 2222

User -User I use to access the cpanel -

But when I try to access through "ssh rafael" of the error "ssh: Could not resolve hostname rafael: Name or service not known". Remember logging in with user and password that I enter in the cpanel but because of workflow question I want to do it this way. Does anyone have any light on what I may be missing?

    
asked by anonymous 23.06.2018 / 00:52

0 answers