Getting ready to use puppetlabs/aws
In the following sections, we'll see how to generate an SSH key pair to connect to your EC2 instances, and also install the puppetlabs/aws
module with its dependencies.
Creating a key pair
You'll need an SSH key pair in order to connect to any EC2 instances you create. We will generate and download your key pair in this section.
- In the AWS console, go to the EC2 section and select Key pairs under Network & Security in the left pane.
- Click the Create Key Pair button.
- You will be prompted for the name of your key pair. Enter
pbg
for this example. - A file named
pbg.pem
will be automatically downloaded by your browser. Move this file to your~/.ssh
directory on your own computer (or copy it to theubuntu
user's~/.ssh
directory on the Vagrant VM, if you'd rather access your AWS instances from there). - Set the correct permissions on the key file with the following command:
chmod 600 ~/.ssh/pbg.pem
Installing the puppetlabs/aws module
Follow these...