Skip to content

Instantly share code, notes, and snippets.

@NetguruGist
Created February 14, 2017 10:02
Show Gist options
  • Save NetguruGist/732ecf2997dec3218f0475fb1ede260b to your computer and use it in GitHub Desktop.
Save NetguruGist/732ecf2997dec3218f0475fb1ede260b to your computer and use it in GitHub Desktop.
apt-get update; apt-get upgrade
apt-get install pwgen whois
/usr/bin/pwgen -s 40 1 (save result internally to Ansible to “root_password” variable)
/usr/bin/mkpasswd {result from root_password} --method=SHA-512 (save internally to “root_crypted_password”)
Set the root password
Print the root password, so that you can see what it is
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment