Tag Archives: The authenticity of host ‘github.com (52.74.223.119)’ can’t be established.

Git push Warning: The authenticity of host ‘github.com (52.74.223.119)’ can’t be established.

The problem:

Created a remote repository on github and pushed my code to it git push -u origin master with the following error

The authenticity of host ‘github.com (52.74.223.119)’ can’t be established.

RSA key fingerprint is SHA256:nThbg6kXUpJWGl7E1IGOCspRomTxdCARLviKw6E5SY8.

Are you sure you want to continue connecting (yes/no)?yes

Warning: Permanently added ‘github.com,52.74.223.119’ (RSA) to the list of known hosts.

[email protected]: Permission denied (publickey).

fatal: Could not read from remote repository.

Reason for the problem: Github and ssh connection requires a key

 

Solution:

1. local mac public key path to get the key: cd ~/.ssh (id_rsa.pub)

2. Login to your own github into the project repository —- into setting —- Deploy keys

3. When configuring the ssh key, check the following Allow write access, the deploy key section in settings to have read and write permissions

4. After the configuration is complete and then go to the project to operate git can

Solution:

git push -u origin master

Enumerating objects: 3, done.

Counting objects: 100% (3/3), done.

Writing objects: 100% (3/3), 218 bytes | 109.00 KiB/s, done.

Total 3 (delta 0), reused 0 (delta 0)

To git+ssh://github.com/illusion1010/Hog.git

* [new branch] master -> master

Branch ‘master’ set up to track remote branch ‘master’ from ‘origin’.