Skip to content

Instantly share code, notes, and snippets.

@vicainelli
Created August 1, 2017 02:43
Show Gist options
  • Save vicainelli/c053fd4285aacb1a48e84d67d6f10472 to your computer and use it in GitHub Desktop.
Save vicainelli/c053fd4285aacb1a48e84d67d6f10472 to your computer and use it in GitHub Desktop.
Lamp Ubuntu 14 .sh
# upgrade existing packages
sudo apt-get update && sudo apt-get -y upgrade
# set timezone
sudo dpkg-reconfigure tzdata
sudo apt-get -y install build-essential ssh curl software-properties-common python-software-properties python g++ make
# install Apache server
sudo apt-get install -y apache2
# install MySQL server (need to type root password)
sudo apt-get install -y mysql-server php5-mysql
sudo mysql_install_db && sudo mysql_secure_installation
# install PHP
sudo apt-get install -y php5 libapache2-mod-php5 php5-mcrypt php5-gd php5-cli
sudo service apache2 restart
# Composer
curl -sS https://getcomposer.org/installer | php
sudo mv composer.phar /usr/local/bin/composer
# other useful packages
sudo apt-get install -y vim git-core
# add phpinfo page
sudo echo "<?php phpinfo();" >> /var/www/html/info.php
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment