Launching WordPress on AWS with RDS

(Ec2, RDS and Httpd WordPress)

✨ In this article I am going to show you, How we can launch a WordPress site over an AWS cloud by using Amazon RDS.

Task Description:-

🔅 Create an AWS EC2 instance
🔅 Configure the instance with Apache Webserver.
🔅 Download php application name “WordPress”.
🔅 As wordpress stores data at the backend in MySQL Database server. Therefore, you need to setup a MySQL server using AWS RDS service using Free Tier.
🔅 Provide the endpoint/connection string to the
WordPress application to make it work.

💥 So let’s start

🔅 Create an AWS EC2 instance

Firstly We need to launch an EC2 Instance on AWS for configure Apache Webserver and run WordPress.

So lets quickly launch an Instance over Aws Cloud

Firstly go to search bar search EC2. Then launch instances. Then follow the image.

Finally I successfully launch the Instance and we can see it in the image.

Now you can use Public IP address any Key to connect this Instance. I used Putty.

🔅 Configure the instance with Apache Webserver.

I am going to configure the Appache webserver because the WordPress site is based on php and html , so the WordPress site is only accessible through the httpd port.

# sudo su -# yum install httpd 

🔅Download php application name “WordPress” and Configure IT.

As WordPress is a php Application, let’s install php 7.2

# amazon-linux-extras install -y php7.2

Let’s got to document root , ie. /var/www/html and download wordpress and install there.

# wget tar -xvzf latest.tar.gz

Now I am Starting Webserver and Enable it Permanently.

# systemctl start httpd# systemctl enable httpd

Setup a MySQL server using AWS RDS service using Free Tier.

Let’s now launch a MySql database using Amazon RDS.

Here is “Endpoint” of this DB Instance using this WordPress Application will connect to it. And this DB Instance is not Having any Internet Access, It can Only connect to Subnets inside VPC. No Public Accessibility!

Provide the Endpoint/Connection string to the WordPress Application

Now Go to the EC2 Instances page and find your instance public Ip then go to http://<publicip>/wordpress/wp-admin/ setup-config.php and fill the details after clicking on Let’s go!

Provide Following Information:

Database Name: Provide Name of Database which created at time of launching DB!

Username: The username you given while launching DB Instance!

Password: Provide Password!

Database Host: Provide the ENDPOINT which you get from “wordpress-db-1”!

Put copied code in “/var/www/html/wp-config.php” at EC2 Instance where WordPress is deployed.

Login with create user and password.

Successfully done! We have Login in to WordPress and we can continue to write Blogs etc., All your Data will Be stored in RDS MySQL DB.

Thanks for reading , I hope you like the Blog!!!




Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

Checkout Field Editor Pro for WooCommerce

Make Linux Works

Humio 1.1: Introducing Views & Repos

Understanding the iterative version of Binary Exponentiation

Add a native macOS file picker to your Flutter application

Introduction to GraphQL & BigCommerce

How to build a free static website with Jekyll and Github Pages

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Mukul Jeveriya

Mukul Jeveriya

More from Medium

The Cheapest VPS Hosting

AdsPower Plus: for Special Branded Customization

How do you install GoLang on Linux?

Best Boat Trips in Dubai