Create a deploy user
The installer by default connects as the root
user only to create a deploy
user. This deploy
user is the one who installs all libraries. If you do not have root
access, please ask your system administrator to follow these instructions to create a user manually.
You could create a user called deploy
or any other name. In this example, we are going to create a user named jupiter
.
Remember to replace jupiter
with whatever username makes sense for you. Input a password when prompted, and leave the rest of the options empty.
Let's create a wheel
group and add the user jupiter
to this group.
Remember to replace "jupiter" with the username you chose earlier.
Now let's give sudo privileges to the wheel
group and allow it to not use a password. This is important to ensure the installer doesn't stall waiting for a password.
First we open the sudoers file:
And we add this line at the end:
Now we need to give the keys of the server to the new user. Don't close the server terminal window, because you can lock yourself out of your server if there is a mistake.
Let's create the necessary directory in the server to upload the public key:
Make sure you have generated a public key in your local terminal.
Open another local terminal window (not in the server) and type:
Copy the content of your public key to the file authorized_keys
that should still be open in the server.
Test that your user can log in by typing:
You should see the server welcome page and a prompt like this:
Note the username at the prompt is not "root", but your username. So everything is fine and we can now block the root account from outside access and also stop allowing password access so only people with SSH keys can log in.
Type the following command to edit the SSH config file of the server:
Look for the "PasswordAuthentication yes" line and change it to "PasswordAuthentication no". Type Control+X
to close the nano editor and type:
Last updated