Pseudo Random Nonsense Generator

Adding sudo user from root user

ยท note

this is tested on digitalocean, with ssh key access enabled and password disabled. further readings here

tested on ubuntu 18.04 on digitalocean

  1. login to your remote server with ssh as root: ssh root@server-ip

  2. adduser your-sudo-user

  3. usermod -aG sudo your-sudo-user

  4. copy over ssh key from root to sudo user: rsync --archive --chown=your-sudo-user:your-sudo-user ~/.ssh /home/your-sudo-user

  5. login remotely with your sudo user! ssh your-sudo-user@server-ip

extras

  • check who you are with whoami
  • switch users with su (short for switch user): su - your-sudo-user / su - root
  • for setups where you ssh into your server with password link