@nickreiner
As @hansen mentioned, there’s really not an exact rule or formula, and much of what you set up will be dependent on what you need.
As a general rule of thumb, don’t install every piece of software on a single server. I’ve seen far too many do that and the end result isn’t a good one. You’ll end up throwing hardware at the issue, and that’s only viable for the short term – long term, it’ll be a mess.
What I normally recommend, and this, of course, depends on your needs, is to separate as much of the software as possible. By that, I mean one server runs the web server (NGINX) and PHP-FPM, one server will run the database (MySQL/MariaDB), one server will be for caching (Redis)
…
As a general note, I recommend Redis over Memcached (with a d) as it’s not finicky about what you store to the cache. There’s an excellent, simple to use WordPress plugin that can be used to connect and from there, it’s pretty much hands-free.
https://wordpress.org/plugins/redis-cache/
…
That being said, keep in mind that the stack is only part of the equation. While you will need to tweak and tune NGINX, MariaDB, and PHP-FPM for performance, WordPress, WordPress Plugins, and your theme(s) come in to play as well.
You could easily have one of the most well-tuned stacks, but far too many plugins, a poorly coded theme, zero asset minification, large images, etc and that well-tuned stack will mean nothing as the site will still crawl.
Performance is as much front-end as it is back-end.
…
I’ve seen servers deployed with 4 physical CPU’s (upwards of 40+ CPU Cores), 128-256GB of RAM (or more), and a RAID-10 SSD array with 10-20 disks crumble because they failed to see that performance wasn’t just about having free resources.
At the same time, I’ve worked with clients that have deployed monster droplets – i.e. multiple 32GB RAM / 12 CPU for web, database, etc, only to see me reduce that down to a single 16GB / 8 CPU for the web server, an 8GB / 4 CPU for the database server, and a 4GB / 2 CPU for the caching server.
The cost for 3x 32GB Droplet’s is $960 a month, with what I converted that to, the cost was far less at $280. That’s all due to working with them on the front and back-end to make sure they were set up as they really needed to be.
…
As far as my auto-installers (thanks for the mention @hansen !), they can be used to simplify much of what you’d need to do on your own.
The NGINX auto-installer is the most complete and comes with tuned configuration. The others, for now, are very basic and simply install software. I’d definitely recommend checking out the NGINX AI as it’ll leave you with a working, tuned NGINX installation (which is compiled from source).
I am working on a newer, more up to date release, with documentation, though I’ll soon be joining DigitalOcean and their Platform Support Specialist team, so much of my time has been spent interviewing and preparing on that front :-). Definitely an exciting time, but that doesn’t mean that I won’t be working on the installers.
If you have any other questions, please feel free to ask. I’ve worked with WordPress sites with low traffic as well as sites that receive upwards of 5-20 million visitors a month.