Skip to content

Instantly share code, notes, and snippets.

@triple-j
Last active March 6, 2016 00:52
Show Gist options
  • Save triple-j/31103c9d143fb607f069 to your computer and use it in GitHub Desktop.
Save triple-j/31103c9d143fb607f069 to your computer and use it in GitHub Desktop.
Setup main user account on Raspberry PI
#!/bin/sh
NEWUSER=$1
if [ -z "$NEWUSER" ]; then
read -p "New User: " NEWUSER
fi
# add main user account
sudo adduser $NEWUSER
sudo usermod -aG sudo $NEWUSER
# disable the pi account
sudo passwd -l pi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment