1- Open the terminal.
2- Generate new ssh keys using your email address
ssh-keygen -t ed25519 -C "[email protected]"
You will be asked for the path of the keys and keyphrarse which is used to secure your keys.
Generating public/private ed25519 key pair.
Enter file in which to save the key (/root/.ssh/id_ed25519): /root/.ssh/git
Enter passphrase (empty for no passphrase):
Enter same passphrase again:
Your identification has been saved in /root/.ssh/git.
Your public key has been saved in /root/.ssh/git.pub.
3- Start the ssh-agent in the background using the following command:
eval "$(ssh-agent -s)"
4- Add the ssh key to ssh-agent using the following command:
ssh-add /root/.ssh/git
5- Add the ssh key to github deploy keys