Created
December 23, 2017 15:54
-
-
Save lucascaires/1a5d53f0edca920c1b110e0cc9a2e8ed to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# My personal LEMP Script for Ubuntu 16.04 | |
#Update packages | |
apt-get update | |
#Install web server | |
apt-get install nginx | |
#Firewall | |
ufw allow ssh | |
ufw allow 'Nginx HTTP' | |
ufw enable | |
#Add Swapfile | |
sudo fallocate -l 1G /swapfile | |
ls -la /swapfile | |
sudo chmod 600 /swapfile | |
sudo mkswap /swapfile | |
sudo swapon /swapfile | |
#Install mysql | |
apt-get install mysql-server | |
mysql_secure_installation | |
#Install PHP 7 | |
apt-get install php-fpm php-mysql | |
apt-get install php-mbstring | |
apt-get install php-gd | |
#Configure nginx file | |
sudo nano /etc/nginx/sites-available/default | |
#Install node, npm and git | |
apt-get install nodejs | |
apt-get install npm | |
apt-get install git | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment