Configuring WordPress and MySQL
Prerequisite:
a. AWS Account
b. Stable Internet Connectivity
c. Little knowledge about EC2
Let's dive into it directly……….
Step-1: Launch an AWS Ec2 instance and login into it.
We are using Amazon Linux Ami
Two instances are needed 1-for frontend and 2nd for the Backend
The frontend must have connectivity and the backend must be in the same subnet as Frontend
Step-2:Installing the httpd software, as we will be using it as a Webserver.
# yum install httpd -y
Step-3: Installing PHP supported for v5.6 of MySQL
As every version of PHP does not support every version of MySQL
# amazon linux extras install php7.4
Step-4: Now installing WordPress
1st download WordPress using wget command and extract it
Copy the extracted WordPress package into httpd document root
which is /var/www/html
Now change the permission of the Apache self-created user to run MySQL
Step-5: Starting the httpd service
# systemctl enable httpd
# systemctl start httpd
Step-6: Now go to WordPress Instance public IP via any browser
We have launched as well configured the WordPress which in turn is connected to MySQL