Week 4, Project 2: Setting up Apache Web Server on EC2 and Serve Amazon EFS Files..

Eric P Ingram
4 min readSep 29, 2020

Walkthrough: Set Up an Apache Web Server and Serve Amazon EFS Files

Follow instructions: Getting Started with Amazon Elastic File System

Step 1: Create Your Amazon EFS File System

Open EFS Management Console and Create File System

Fill in Name — optional box as desired and select your VPC or leave the default VPC in the Virtual Private Cloud (VPC) drop down box, Click Create

Click View Details to see the following page.

(Right Screen Only, forgot to cut out left.)

Step 2: Create Your EC2 Resources and Launch Your EC2 Instance

Create a Key Pair

From the AWS Management Console, Click EC2

In the EC2 Resources, Click Key Pairs then Create Key Pairs

Enter a descriptive Name for the key pair. A key name can include up to 255 ASCII characters. It can’t include leading or trailing spaces.

Choose the File format in which to save the private key. To save the private key in a format that can be used with OpenSSH, choose pem. To save the private key in a format that can be used with PuTTY, choose ppk.

Choose Create Key Pair.

Create a Security Group

From the navigation bar of the AWS Management Console, select a Region for the security group. Security groups are specific to a Region, so you should select the same Region in which you created your key pair.

In the navigation pane, choose Security Groups.

Choose Create security group

In the Basic details section, do the following:

Enter a name for the new security group and a description.

In the VPC list, select your default VPC for the Region.

In the Inbound rules section, create the following rules (choose Add rule for each new rule):

  • Choose HTTP from the Type list, and make sure that Source is set to Anywhere (0.0.0.0/0).
  • Choose HTTPS from the Type list, and make sure that Source is set to Anywhere (0.0.0.0/0).
  • Choose SSH from the Type list. In the Source box, choose My IP to automatically populate the field with the public IPv4 address of your local computer.
  • Choose Create security group.

The results of Creating the Security Group with Inbound Rules.

On the AWS Management Console, Click EC2.

Choose Launch Instance.

Choose an Amazon Machine Image (AMI), and Click Select.

Choose an Instance Type, Click Next: Configure Instance Details.

Configure Instance Details, configure Network, Subnet, File Systems and User Data as shown:

Click Next: Add Storage.

Click Next: Add Tags.

Click Next: Configure Security Group.

(Assign a security group to Select an existing security group.)

Click Review and Launch.

Choose Launch on the Review Instance Launch page then Select the check box for the key pair that you created, and then choose Launch Instances.

--

--