How to install Cacti (a system monitoring and graphing solution) with Nginx?

Here's a short tutorial on installing Cacti with Nginx on Linux.