Skip to content
The Chat Archive
gpt-3.5-turbo-0301· OpenAI WildChat-4.8M (AI2)

ssh-copy-id

  1. User

    ssh-copy-id

  2. Assistant

    The ssh-copy-id command is a utility that simplifies the process of adding a public SSH key to a remote machine's authorized_keys file. This allows for secure and easy access to the remote machine without requiring a password every time you connect via SSH.

    The command is used in the following syntax:

    ssh-copy-id [username]@[remote-host]
    

    For example, to copy the public key of user "johndoe" to a remote machine with the IP address "192.168.1.100", you would use the following command:

    ssh-copy-id johndoe@192.168.1.100
    

    The command will prompt you to enter the password for the remote machine's user account. Once authenticated, the public key will be copied to the remote machine's authorized_keys file and you will be able to connect to the remote machine via SSH without entering a password.