I want to pull two private github repos via bash script to my server. I used to do just one and this worked fine. This is the process that worked for me:
- Generate SSH on server
- Add to github repo’s ssh list
- Compelte the git pull request
Now I am trying to do this:
- Generate SSH
- Add key to first github repo’s ssh list
- Add key to second github repo’s ssh list
- Compelte the first repo git pull request
- Compelte the second repo git pull request
However, when I try to add the same key to the second repo I want to copy, github says it is already in use. How am I supposed to do this? Should I be generating two seperate SSH’s keys on the server and use one for one github repo and one for the other?
SSH keys on github are user-specific and not repo-specific.
Did you try to simply git pull from second repo after pulling from the first?