Setting Up WordPress on AWS

Fri, Dec 4, 2015

First blog post has to be documenting how I’m setting up this blog!  Going to keep in very technical.  Need an EC2 instance, running Ubuntu, with WordPress using Nginx with the AddThis plugin for sharing tools, email against Google Apps for Business server, and backing up to S3 with Backup Buddy plugin.

  • Using an Amazon EC2 instance type of t2.micro, costs $151 for 3 years, running the latest Long Term Service (LTS) edition of ubuntu.  I have a Virtual Private Cloud (VPC) with a persistent connection (thank you NetGate) to my home network so my security groups will differ.  Maybe I’ll do a post about that setup later.  Also need an elastic IP for public Internet access to instance http(s) ports.

  • Adding creature comforts, love me some ZSH

Nginx / MySQL / PHP

You will need to update your nginx config file  /etc/nginx/sites-available/default to look like this:

SSL

WordPress

Sharing Tools

Adding AddThis tools: Just go to plugins and search for AddThis Sharing Tools and install

S3 Policy

Setting S3 storage.  I create a new bucket and IAM role for each web app. Here is the IAM policy that will help you keep permissions setup correctly.

Email

We will use postfix with Google Apps for Business mail servers for emails

BackupBuddy

BackupBuddy does scheduled backups very well. I already had a license for the product and after installing and connecting to Amazon S3 I have no worries that everything is backed up.

References:

https://www.digitalocean.com/community/tutorials/how-to-install-linux-nginx-mysql-php-lemp-stack-on-ubuntu-14-04

https://www.digitalocean.com/community/tutorials/how-to-install-wordpress-with-nginx-on-ubuntu-14-04

https://community.runabove.com/kb/en/instances/how-to-relay-postfix-mails-via-smtp.gmail.com-on-ubuntu-14.04.html

https://ithemes.com/purchase/backupbuddy/