LEMP is a complete package to run any web application on a server. LEMP signifies the Linux, Nginx, MySQL and Php. Nginx is used as the web server for hosting of an application whereas MySQL is used as systematic data storage of application & Php is popular server-side scripting language which is used for web development as well bridging the gap between application and the database.
Step 1. Open your EC2 Terminal and update your Packages.
Step 2. Install nginx webserver.
Step 3. Now direct your browser to http://ip and you should see the Nginx page like this.
Step 4. Install mysql-server in your Machine by running bellow command from your terminal.
Step 5. Specify New password for Mysql root user.
Note: Confirm Password for Mysql root user.
To know more visit : How to Install Nginx, Mysql, PHP ( LEMP ) Server on Ubuntu 16.04