Practical tasks to learn more about DevOps

Difficulty: [ ]

Task 06. Run wordpress with multiple application servers.

After splitting up database and application load on servers decreased for some time. You were happy that you can separately operate on each server. One night on your server with wordpress - application server, logs felt all the disc space and web site wasn’t working. Paul was not very happy about it, but as he was experienced, he knew that we learn faster on failures. He asked if you heard anything about vertical and horizontal scaling and advised you to read about it and make Magazine more reliable so if one server fails, the other keeps working.

Task

  • Repository: Fork repository for task06 and clone forked repo.

  • Provision reliable Wordpress : Setup Wordpress using Ansible and Vagrant, but this time there would be 4 VMs:
    1. database, where MySQL is running
    2. 2 * wordpress, where nginx and php are running, it should point in a configuration in database VM.
    3. lb, where Load balancer would redirect requests to both wordpress VMs. For load balancer you can use different programs of your choice: nginx, apache-http, traefik, or any other.
  • Multimedia files always available: After successfully deploying wordpress try to create a new post with five different images. Try to refresh the page 7 times. Make sure that every time page is refreshed all pictures are visible.

  • Source code: Create a pull request to the repository that you forked, so that you can get comments on your code.

Additional tasks if you feel that it was too easy.

  1. N/A

Tips:

  • Check out on the internet what is the difference between vertical and horizontal scaling.
  • Check out on the internet what types of load balancers and their features, like session stickiness.

FAQ

  • N/A

Heroes of the task:

@dbemol

Devan