Server Setup on Instances

Install Apache

sudo apt-get install apache2-mpm-prefork
sudo a2enmod userdir
sudo a2enmod expires

Restart Apache

sudo /etc/init.d/apache2 restart 
sudo service apache2 restart

Install MySQL

sudo apt-get install mysql-server mysql-client

Create DB user in MySQL

CREATE USER 'username'@'localhost' IDENTIFIED BY 'password';
CREATE DATABASE db_name;
GRANT ALL ON db_name.* TO 'username'@'localhost';

Install PHP

sudo apt-get install php5 libapache2-mod-php5 php5-mcrypt
sudo apt-get install libapache2-mod-php5

 

Advertisements