Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8972005
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T18:06:23+00:00 2026-06-15T18:06:23+00:00

There are lots of stack articles citing the same error message as I am

  • 0

There are lots of stack articles citing the same error message as I am getting.

I went through the entire heroku setup doc on another computer and everything worked perfectly. Not sure why this one is not working, but I need it to.

When I run:

> git push -v heroku master

Pushing to git@heroku.com:lit-tor-7969.git
Permission denied (publickey).
fatal: The remote end hung up unexpectedly

All of the solutions on Stack involve reseting the ssh keys, and I believe the ssh keys are fine. I am on Mac OSX and have run:

heroku keys:clear
heroku keys:add

So it looks to me like the git is using /Users/bishopz/.ssh keys rather than the keys I generated manually inside the repository folder.

In addition to the answers below, this article seems to be providing a lot of insight:
Cannot push to Heroku because key fingerprint

I tried completely removing the .ssh directory. I ran

heroku keys:clear
ssh-add -D #to remove all ssh identities
ssh-keygen -t rsa -C "email@gmail.com" -f  ~/.ssh/id_rsa_heroku
ssh-add ~/.ssh/id_rsa_heroku
heroku keys:add ~/.ssh/id_rsa_heroku.pub
git push heroku master

and now get:

!  Your key with fingerprint 27:5f:64:4e:2e:f0:41:5b:62:a9:95:d2:02:df:27:85 is not authorized to access lit-tor-7969.
fatal: The remote end hung up unexpectedly

The response to

ssh -vvv git@heroku.com

is now:

debug1: Host 'heroku.com' is known and matches the RSA host key.
debug1: Found key in /Users/bishopz/.ssh/known_hosts:1
debug1: ssh_rsa_verify: signature correct
debug1: Offering RSA public key: /Users/bishopz/.ssh/id_rsa_heroku
debug1: Server accepts key: pkalg ssh-rsa blen 279
debug1: Authentication succeeded (publickey).
Authenticated to heroku.com ([50.19.85.132]:22).

Any help appreciated, I’ll start a new bounty if someone can post an answer that works for me.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T18:06:25+00:00Added an answer on June 15, 2026 at 6:06 pm

    Okay, I was able to solve it. Several of these answers were helpful. It seem that two things had happened.

    First, based on this article the ssh keys had gotten confused. This was resolved by deleting the .ssh directory (of course this removed all the credentials for other things that use .ssh, but those can be recreated later):

    heroku keys:clear
    ssh-add -D #to remove all ssh identities
    ssh-keygen -t rsa -C "email@gmail.com" -f  ~/.ssh/id_rsa_heroku
    ssh-add ~/.ssh/id_rsa_heroku
    heroku keys:add ~/.ssh/id_rsa_heroku.pub    
    

    Secondly, based on an answer to this article the app name had somehow changed during the process of troubleshooting the ssh keys. The app name had to be manually edited in /repository_folder/.git/config

    To get the correct app name I logged into heroku.com on the web and then updated the config file:

    it’s contains

    [remote "heroku"]
        url = git@heroku.com:my_new_app_name.git
        fetch = +refs/heads/*:refs/remotes/heroku/*
    

    Thanks to all that posted suggestions! I am so happy to finally be on my way to a new app!

    –UPDATE–

    I have to rerun this command every time I reboot the computer. I can add it my .profile or whatever, but thought it was worth a note.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I know there are lots of stack overflow posts about this. I have this
i want to send mail through iphone sdk i know there are lots of
There's lots of questions on SO related to this, but the ones I scanned
There's lots of good material on Design Patterns out there that covers how you
There are lots of implementations for validating Luhn checksums but very few for generating
There are lots of Fluent implementations out there now that work with Lambdas to
There are lots of java apps on my simulator menu screen which I have
There are lots of tutorials/instructions on how to embed python in an application, but
There are lots written about the ReaderWriterLockSlim class which allows multiple read and a
There are lots of questions on how to strip html tags, but not many

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.