Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Permission denied (publickey,gssapi-keyex,gssapi-with-mic) on openshift

I am having issues with committing changes to my gear. I have tried to run rhc setup, I also deleted my .ssh folder and executed rhc setup again but that also didnt work.

Not sure what changed but it worked couple of hours ago.

>git push -u <GEAR_NAME> master Permission denied (publickey,gssapi-keyex,gssapi-with-mic). fatal: Could not read from remote repository.  Please make sure you have the correct access rights and the repository exists.  >git remote add devstage3 -f ssh://<GEAR_ID>@<GEAR_NAME>-<GEAR-DOMAIN>.rhcloud.com/~/git/<GEAR_DOMAIN>.git/  

Also I have tried to start a different gear and commit to it but I am getting the same error:

Updating <GEAR_NAME> The authenticity of host '<GEAR_NAME>-<GEAR-DOMAIN>.rhcloud.com (<GEAR_IP>)' can't be established. RSA key fingerprint is <KEY_FINGERPRINT>. Are you sure you want to continue connecting (yes/no)? yes Warning: Permanently added '<GEAR_NAME>-<GEAR-DOMAIN>.rhcloud.com,<GEAR_IP>' (RSA) to the list of known hosts. Permission denied (publickey,gssapi-keyex,gssapi-with-mic). fatal: Could not read from remote repository.  Please make sure you have the correct access rights and the repository exists. error: Could not fetch <GEAR_NAME> 
like image 986
special0ne Avatar asked Feb 03 '14 00:02

special0ne


People also ask

How do I fix ssh failed Permission denied Publickey Gssapi Keyex Gssapi with mic Windows?

Solution 1: Enable Password Authentication In the file, find the PasswordAuthentication line and make sure it ends with yes . Find the ChallengeResponseAuthentication option and disable it by adding no . If lines are commented out, remove the hash sign # to uncomment them. Save the file and exit.

Why do I get permission denied Publickey?

"Permission denied (publickey)" and "Authentication failed, permission denied" errors occur if: You're trying to connect using the wrong user name for your AMI. The file permissions within the operating system are incorrect on the instance. The incorrect SSH public key (.


2 Answers

if you are using Windows, you can try the following steps:

  1. look for your ssh public key usually you can find it at c:\\users\\YOUR_USERNAME\\.ssh

  2. copy your openshift public key to your git's ssh-key folder

    suppose we have git in d:\\git

    then we need to copy the public key from c:\\users\\YOUR_USERNAME\\.ssh to d:\\git\\.ssh

  3. try if it works

like image 69
boris1993 Avatar answered Oct 04 '22 03:10

boris1993


Remove the keys: rhc sshkey-remove You can also delete them from the management console, by going to https://openshift.redhat.com/app/console/settings

Once done, upload the public key (copy the content of your id_rsa.pub to management console) : https://openshift.redhat.com/app/console/keys/new

Save it. After this try to git clone and it should work for you.

like image 26
special0ne Avatar answered Oct 04 '22 03:10

special0ne