Quantcast
Viewing all articles
Browse latest Browse all 6142

Cloning Multiple repos on Ec2 | .ssh config error

Problem statement : Clone 2 repos from Github

Actions Taken :

  1. Created 2 ssh keys and added to corresponding repos's deploy keys.

  2. Create a config file in Home/Ubuntu/.ssh folder

    Host aimer-ui github.comHostName github.comIdentityFile /home/ubuntu/.ssh/id_rsa_new.pub

    Host aimer-service github.comHostName github.comIdentityFile /home/ubuntu/.ssh/id_rsa.pub

Error Coming on Cloning :

Cloning into 'aimer-ui'...Load key "/home/ubuntu/.ssh/id_rsa_new.pub": error in libcryptoLoad key "/home/ubuntu/.ssh/id_rsa.pub": Permission deniedgit@github.com: Permission denied (publickey).fatal: Could not read from remote repository.Please make sure you have the correct access rightsand the repository exists.ubuntu@ip-172-31-44-226:~$ git clone git@github.com:BeA-Brand/aimer-service.gitCloning into 'aimer-service'...Load key "/home/ubuntu/.ssh/id_rsa_new.pub": error in libcryptoLoad key "/home/ubuntu/.ssh/id_rsa.pub": Permission deniedgit@github.com: Permission denied (publickey).fatal: Could not read from remote repository.Please make sure you have the correct access rightsand the repository exists.

My Observation : Same ssh being used in cloning the repos. But in that case, atleast one repo would have worked.


Viewing all articles
Browse latest Browse all 6142

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>