Automating the Deployment of a Scalable WordPress Site
Introduction
In this guide we will create and deploy a scalable WordPress instance consisting of a MySQL database server, a GlusterFS distributed filesystem, Nginx web servers and an Nginx load balancer. By using user-data and droplet meta-data we will automate the deployment of our site. Finally we will provide a Ruby script which will automate this entire process and ease the creation of scalable WordPress sites. Through this tutorial you will learn about the power and flexibility of user-data and droplet meta-data in deploying services on DigitalOcean.
Step One – Planning our Deployment
The deployment we create in this tutorial will consist of a single MySQL database server, multiple GlusterFS servers in a cluster, multiple Nginx web servers and a single Nginx load balancer.
Before we begin we should know:
- What size droplet we will use for our MySQL server
- How many GlusterFS nodes we will create
- What size our GlusterFS nodes will be
- How many web server nodes we will need
- What size droplets we will use for our web servers
- What size droplet we will use for our load balancer
- The domain name we will use for our new site
We can add additional nodes or scale up the nodes we created if we need to later. Once we have decided on these details we can begin deploying our site.