Created
May 29, 2019 23:21
-
-
Save benhg/6f8257300453eda6c2bf32ce45c06442 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
USER='username' | |
PASS='passwd' | |
sudo useradd -m -d /home/$USER --password $(echo "$PASS" | openssl passwd -1 -stdin ) $USER | |
# omit 1,2 if env variables are otherwise set. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment