9/16/2023 0 Comments Add ssh key to mac![]() Your command might look like this: ssh -l userName -i pathToKey remoteHostName.This should go before the remote host name. If the private key has a non-default name or directory, include the -i flag followed by the correct directory and name.If your local machine account name is different from your login username, include the -l flag followed by your login username.In a terminal, type the command ssh followed by the remote host name.Upload the public key file (the one ending in .pub).You will be asked to retype the password for confirmation. Enter a password for the key pair, and press enter.By default, keys are saved in the ~/.ssh directory with the names id_rsa, id_rsa.pub.If a file name is supplied, the key pair will be saved in the terminal's current directory with the supplied name.When asked to enter file in which to save the key, press enter without typing in a name. ![]() ![]() To save the key pair in other than the default directory of ~./ssh or with a different name, add the -f flag followed by the directory and key pair name (e.g.In a terminal, type the command ssh-keygen -t rsa, and press enter. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |