What is Laravel ?
Laravel is a free, open source PHP web application framework, designed for the development of web applications. Laravel was listed as the most popular PHP framework according to a December 2013 developers survey on PHP frameworks popularity.
Laravel can be installed with our Linux VPS plans. With the below steps you can install Laravel on cPanel installed Linux servers.
If you wish to manage Laravel and access it, make sure shell access is enabled on your cPanel account.
[[email protected] ~]# cd /bin
[[email protected] ~]# wget https://getcomposer.org/installer
Once the installer is downloaded, make sure if the server is setup properly and compatible for Laravel installation.
[[email protected] ~]# php installer –check
If the server is compatible, it will show an output All settings correct for using Composer. Else, it will show the errors that needs to be fixed.
Now, that the server is compatible to install Laravel let’s proceed with installing it.
[[email protected] ~]# php installer
Once the installation completes, make sure to remove the installer file.
If you wish to install it for any specific domain, access the root directory for the cPanel account and execute the command below.
[[email protected] ~]# php /bin/composer.phar create-project laravel/laravel –prefer-dist
It will now download & install Laravel for you. Rename your existing public_html directory and create a symlink. Update the ownership of the laravel directory.
[[email protected] ~]# mv public_html public_html_backup
[[email protected] ~]# chown cPanel-user.cPanel-user laravel/public -R
[[email protected] ~]# ln -s laravel/public/ public_html
You can browse the website and see if it shows output as Laravel 5. If it does, the Laravel installation has been successful.