sudo apt-get update -y
sudo apt install apache2 // install apache 2
sudo ufw app list // adjust your firewall settings to allow HTTP traffic
sudo ufw allow in "Apache"
sudo ufw status // check status
sudo apt install mysql-server // install mysql database
sudo mysql_secure_installation // set user and password
sudo mysql // enter into database to verify
exit // exit from database
sudo apt install php libapache2-mod-php php-mysql // install latest php and php-ext
php -v // verify php version