SYS 360 Lab 5 3: Lab 5 3: Setting up WordPress on LAMP - JadenGil/Jaden-Tech-Journal GitHub Wiki

Before doing this lab make sure this lab is completed first since this is part 3 of 3:

*** Installing WordPress:

Install Wordpress using wget https://wordpress.org/latest.tar.gz:

image

Then un-tar it with tar -xzf latest.tar.gz:

image

Make sure that mariadb is running:

active!

Now we want to log into the database:

image

Then we will want to make a new user:

image

Then we will make the Wordpress database and grant all privileges to User1:

image

Run FLUSH PRIVILEGES; afterwards too!!

Then we can exit Mariadb client.


Create and Edit the wp-config.php File:

Copy the Wordpress sample file using cp wordpress/wp-config-sample.php wordpress/wp-config.php

Then use nano wordpress/wp-config.php to edit the following:

image)

Then in the section highlighted in the screenshot copy and paste the salts from the page https://api.wordpress.org/secret-key/1.1/salt/:

image

Then we can save the file and exit


Installing your WordPress Files Under the Apache Document Root:

Copy the contents of the Wordpress directory using cp -r wordpress/* /var/www/html/

Then we will edit httpd.conf by using sudo nano /etc/httpd/conf/httpd.conf

Then find the highlighted section of the file and allow override all:

image

Then exit and save the file


Install the PHP graphics drawing library on Amazon Linux 2:

To do this run sudo yum install php-gd and once installed verify the install with sudo yum list installed | grep php it should look like this:

image

Now we will want to grant the proper privileges to the proper directories if not done already:

image

Then restart httpd.


Running the WordPress Installation Script with Amazon Linux 2:

We want to make sure that all of our database programs run at startup so we can use sudo systemctl enable httpd && sudo systemctl enable mariadb to enable that.

Then make sure that mariadb is still running:

image

Same with httpd:

image


Deliverables:

Deliverable 1:

image

http://18.234.204.207/wp-admin/