Skip to content

Latest commit

 

History

History
32 lines (24 loc) · 707 Bytes

server-configuration.md

File metadata and controls

32 lines (24 loc) · 707 Bytes

create new user with sudo privileges

sudo adduser username

Grant privilages.

sudo usermod -aG sudo username

Use the su command to switch to the new user account.

su - username

Usefull ssh commands

Use this command to remove entries from known_hosts:

ssh-keygen -R hostname
# works with ips as well

Create file authorized_keys and copy data to it from the root file. It can be done via

rsync --archive --chown=sammy:sammy ~/.ssh /home/sammy

https://www.digitalocean.com/community/tutorials/initial-server-setup-with-ubuntu-18-04

https://www.digitalocean.com/community/tutorials/automating-initial-server-setup-with-ubuntu-18-04