This project is built on Learner Lab using AWS EC2 and RDS to create a searching airline's website.
Follow these steps to set up the project:
-
Build your EC2 instance by following the instructions in the AWS documentation.
- Make sure to use an Elastic IP to ensure your Public IPv4 address does not change. You can allocate an Elastic IP address and associate it with your EC2 instance. Here's how to do it:
- Go to "Elastic IPs" in the AWS Management Console.
- Allocate an Elastic IP address.
- Go to "Actions" and select "Associate Elastic IP address".
- Choose your EC2 instance and enter your private IPv4 address.
- Click "Associate".
- Make sure to use an Elastic IP to ensure your Public IPv4 address does not change. You can allocate an Elastic IP address and associate it with your EC2 instance. Here's how to do it:
-
Build your RDS database by following the instructions in the AWS documentation.
-
Change the code in
airline.html
,ctb.php
, andindex.php
.- Replace "YOUR EC2 IPV4" with your Public IPv4 address.
-
Build your S3 bucket and upload the following files:
airline.html
ctb.php
index.php
101.jpg
123.jpg
789.jpg
-
Install a web server on your EC2 instance by following the instructions in the AWS documentation.
- Make sure to update the
dbinfo.inc
file with yourDB_SERVER
,DB_USERNAME
,DB_PASSWORD
, andDB_DATABASE
information.
- Make sure to update the
-
Transfer the files from S3 to your EC2 instance:
cd /var/www/html sudo aws s3 cp ctb.php /var/www/html/ sudo aws s3 cp airline.html /var/www/html/ sudo aws s3 cp index.php /var/www/html/ sudo aws s3 cp 101.jpg /var/www/html/ sudo aws s3 cp 123.jpg /var/www/html/ sudo aws s3 cp 789.jpg /var/www/html/
-
Open your website by accessing the following URL in your web browser:
http:// Public IPv4 address /airline.html