Cannot push to heroku

heroku, key, public-key

Solution

Try to re-generate the public key (`id_pub.rsa`), then add it again to heroku.

ssh-keygen -t rsa -C "your_email@youremail.com"
heroku keys:clear
heroku keys:add

Problem

I have Windows 7 Home Premium with installed: ``` gem 1.8.24 ruby 1.9.3p385 node 0.8.19 git 1.8.1.msysgit. heroku/toolbelt/2.35.0 (i386-mingw32) ruby/1.9.3 ``` I can succefully login to heroku with: `heroku login`. Even when I clear keys: `heroku keys:clear` and generate new one `heroku keys:add` I have result success! When I login to heroku webpage-> my account I have correctly added key. I'm added to project as collaborator. ``` git remote add heroku-s git@heroku.com:secret-project.git ``` Problem is, when I try to push files to heroku with: ``` git push heroku-s master ``` I get error: ``` Permission denied (publickey). fatal: Could not read from remote repository. Please make sure you have the correct access rights and the repository exists. ``` Any suggestions?

Original source