I am having some issues with using git (github) on a remotely accessed machine. I am logging in from home into my work computer via ssh e.g.
me@home$ ssh me@work after which I try to do a pull or push request to github on my work computer via home e.g.
me@workViaHome$ git pull origin branch after which I receive the error:
Permission denied (publickey). fatal: Could not read from remote repository. Please make sure you have the correct access rights and the repository exists. I have tried loading the ssh key from my work computer using:
me@workViaHome$ eval "$(ssh-agent -s)" me@workViaHome$ ssh-add ~/.ssh/id_rsa but still no luck. When I am physically at my work computer I can issue requests to github without any issues; so it seems the issue with with the status of my ssh-keys due to my ssh session.
Thanks for any help!