Skip to content

Instantly share code, notes, and snippets.

@jamiekurtz
Last active May 16, 2016 18:28
Show Gist options
  • Save jamiekurtz/3025c79a4cd14174cecd343bce61ccf9 to your computer and use it in GitHub Desktop.
Save jamiekurtz/3025c79a4cd14174cecd343bce61ccf9 to your computer and use it in GitHub Desktop.
New user (with SSH key) on Ubuntu
sudo adduser --disabled-password newuser
sudo su - newuser
mkdir .ssh
chmod 700 .ssh
touch .ssh/authorized_keys
chmod 600 .ssh/authorized_keys
# then copy in public key
# to add new user to sudo group
sudo adduser newuser sudo
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment