Setting up WordPress with Kubernetes clusters
In this recipe, we will use the WordPress example given in the Kubernetes documentation (https://kubernetes.io/docs/tutorials/stateful-application/mysql-wordpress-persistent-volume/). There are three parts to this example: creating a secret, deploying MySQL, and deploying WordPress.
Getting ready
Follow these prerequisites:
- Make sure that the Kubernetes cluster has been set up, as described in the previous recipe.
- There are two pod files that we need to download. You can find them here:
- These YAML files describe pods and services for MySQL and WordPress, respectively.
- MySQL and WordPress each require a place to store their data. In Kubernetes, this is called a PersistentVolume. When we deploy our pod, the PersistentVolumeClaims will be created. Different clusters have different default storage classes...