Я использую Ubuntu, и у меня есть несколько ключей, которые я использую для подключения к удаленным машинам.
Ключ, который я создал с помощью ssh-keygen -t rsa
, находится в моей домашней папке по адресу ~/.ssh/
и называется rsa_id
.
У меня есть другой ключ, который используется командой DevOps в моей компании, и я хочу, чтобы он стал ключом по умолчанию.
Я просмотрел файл /etc/ssh/sshd_config
и там есть такая строка:
HostKey /etc/ssh/ssh_host_rsa_key
Так что я хотел спросить о двух вещах:
1. When I issue my key using the command specified above, does it copy the content of my newly created key to this file?
2. If I want to change the default key used, shall I add another `HostKey` line and point it to the DevOps key?
Спасибо
Hi I believe this is the answer to your question. I did not want to copy paste the answer.
https://superuser.com/questions/263405/how-do-we-specify-an-ssh-default-identity