Last active
December 2, 2019 15:21
-
-
Save linuxfemale/a8beda8c1069a41ebd7a662311b142eb to your computer and use it in GitHub Desktop.
Laravel PHP Framework On Ubuntu 18.04
This file contains 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
sudo apt update | |
sudo apt install apache2 | |
sudo systemctl stop apache2.service | |
sudo systemctl start apache2.service | |
sudo systemctl enable apache2.service | |
sudo apt install php7.2 libapache2-mod-php7.2 php7.2-mbstring php7.2-xmlrpc php7.2-soap php7.2-gd php7.2-xml php7.2-cli php7.2-zip | |
sudo nano /etc/php/7.2/apache2/php.ini | |
memory_limit = 256M | |
upload_max_filesize = 64M | |
cgi.fix_pathinfo=0 | |
curl -sS https://getcomposer.org/installer | sudo php -- --install-dir=/usr/local/bin --filename=composer | |
cd /var/www/html | |
sudo composer create-project laravel/laravel TestProject --prefer-dist | |
sudo chown -R www-data:www-data /var/www/html/TestProject/ | |
sudo chmod -R 755 /var/www/html/TestProject/ | |
sudo nano /etc/apache2/sites-available/laravel.conf | |
<VirtualHost *:80> | |
ServerAdmin admin@localhost | |
DocumentRoot /var/www/html/TestProject/public | |
ServerName localhost | |
<Directory /var/www/html/TestProject/public> | |
Options +FollowSymlinks | |
AllowOverride All | |
Require all granted | |
</Directory> | |
ErrorLog ${APACHE_LOG_DIR}/error.log | |
CustomLog ${APACHE_LOG_DIR}/access.log combined | |
</VirtualHost> | |
sudo a2ensite laravel.conf | |
sudo a2enmod rewrite | |
sudo systemctl restart apache2.service | |
http://localhost/ | |
#vedio tutirial | |
https://www.youtube.com/watch?v=KxlJSoo4P10 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment