Working with AWS RDS

Working with AWS RDS

Hola readers! Today I am going to show you how we can set up a basic AWS RDS setup and use it with the front end which in my case would be Wordpress. First let's see what is AWS RDS.

AWS RDS

GicCohP2z3musf3sEZgcyf.png

Amazon Relational Database Service (Amazon RDS) makes it easy to set up, operate, and scale a relational database in the cloud. It provides cost-efficient and resizable capacity while automating time-consuming administration tasks such as hardware provisioning, database setup, patching and backups. It frees you to focus on your applications so you can give them the fast performance, high availability, security and compatibility they need.

Amazon RDS is available on several database instance types - optimized for memory, performance or I/O - and provides you with six familiar database engines to choose from, including Amazon Aurora, PostgreSQL, MySQL, MariaDB, Oracle Database, and SQL Server. You can use the AWS Database Migration Service to easily migrate or replicate your existing databases to Amazon RDS.

Let's Start

For this demo our set up will be like this:

  • An EC2 instance which will host our front end WordPress
  • RDS for the backend database

First, let's set up our front end. For this launch an ec2 instance as per your requirements.

Screenshot (1099).png

Now ssh into the instance and then we will configure WordPress inside. For configuring WordPress there are multiple ways but here I use container image to setup WordPress easily. To do this we have to install docker.

Screenshot (1103).png

Now we have to pull the WordPress image from the docker hub.

Screenshot (1104).png

Screenshot (1105).png

Now all that's left is to run the container.

Screenshot (1106).png

Our front end is now ready. Let's set up our back end now.

For this go to the RDS section and then to the database and create a new database.

Screenshot (1100).png

Here fill out all the relevant info like database name, password, backup, scalability, etc according to your requirements and then create it and our database will be ready in a few minutes.

Screenshot (1115).png

Now we just go to your instance's public IP and you will be able to see the WordPress site.

Screenshot (1107).png

And then fill out the database information which you used while creating RDS like this. For database host, you have to provide your RDS endpoint URL which you can find by clicking the database name in RDS.

Screenshot (1108).png

Now our setup is ready.

Screenshot (1113).png

Screenshot (1114).png

This way we can configure RDS and use it in a simple way. That's it for this one and see you next time ...!!

Did you find this article valuable?

Support Written Wisdom by becoming a sponsor. Any amount is appreciated!