hands-on lab

Deploying Wordpress using AWS CloudFormation

Difficulty: Beginner
Duration: Up to 1 hour
Students: 5,582
Rating: 4.4/5
Get guided in a real environmentPractice with a step-by-step scenario in a real, provisioned environment.
Learn and validateUse validations to check your solutions every step of the way.
See resultsTrack your knowledge and monitor your progress.

Description

Amazon CloudFormation is a popular way to make interacting with AWS repeatable. It lets you create complex infrastructure with easy-to-understand JSON specifications. CloudFormation permits you to specify in JSON all of the AWS resources that make up your infrastructure and handles creating and connecting them automatically. It also makes scaling up a snap!

A CloudFormation stack can manage a variety of things: DynamoDB tables, Elastic IPs, EC2 instances, Virtual Private Cloud networks, security groups, Route53 zones and records, IAM users, CloudWatch logs and alarms, S3 buckets, and much more.

In this lab, you will use CloudFormation to launch an EC2 (Linux) instance with a full WordPress installation. The template formatting supports either JSON or YAML. For this lab, the CloudFormation template used will be in JSON format.

Learning objectives

Upon completion of this lab, you will be able to:

  • Deploy infrastructure using AWS Cloud Formation
  • Manage Cloud Formation stacks

Prerequisites

Familiarity with the following will be beneficial but is not required:

  • AWS CloudFormation
  • Amazon Elastic Compute Cloud (EC2)

The following content can be used to fulfill the prerequisites:

Updates 

March 15th, 2023 - Updated screenshots to reflect the latest user interface

February 4th, 2022 - Updated validation check function

January 5th, 2022 - Updated screenshots and instructions to reflect the latest UI

July 16th, 2020 - Improved lab formatting for an improved learning experience. Updated content to reflect the latest AWS Console experience

May 14th, 2019 - Update code for installing PHP and Apache to satisfy new version constraints

January 10th, 2019 - Added a validation Lab Step to check the work you perform in the Lab

Environment before

Environment after

Covered topics

Lab steps

Logging In to the Amazon Web Services Console
Creating an AWS CloudFormation stack
Checking the status of the stack
Viewing resources in a stack
Deleting the stack