DevOps for the Desperate:
Table of Contents
Chapter Two
Generating Complex Passwords
I used a tool outline in the book.
sudo apt update
sudo apt install pwgen whois
Without giving specific copywright details from the book I’ll just tell you what was done here.
First: We will use a tool call pwgen and whois in the install commands from above to create a random password store it in an environment variable for temporary use. Then in a separate command "echo" the stored pwgen into 'mkpasswd' to supply the sha-512 algo' to it and then echo it back out to the terminal.
Then: Use the password hash generated from 'mkpasswd' in the user_and_group.yml file provided from the intro section of the book.
On the newest version of MacOS (Tahoe 26), I had an issue with mkpasswd so I had to pull down an older version of the tool. I used