Laravel configuration with apache

September 22, 2015 16.3k views

Please help me with laravel configuration for making it work with apache

1 Answer

You should be able to install a Laravel app just like any other website. See How To Set Up Apache Virtual Hosts on Ubuntu 14.04 LTS.

You'll need to install a couple of PHP extensions that Laravel needs:

sudo apt-get install php5-mcrypt php5-json
sudo php5enmod mcrypt
sudo php5enmod json
sudo service apache2 restart

The rewrite module should be enabled by default, but if your routes aren't working properly, try enabling it:

sudo a2enmod rewrite
sudo service apache2 restart

Finally, you need to grant Laravel write permissions to the app/storage directory:

sudo chown -R www-data:www-data /var/www/
by Justin Ellingwood
The Apache web server is the most popular way to serve web content on the internet. Apache has the ability to serve multiple domains from a single server by using a mechanism called "virtual hosts". If a virtual host is configured correctly for each domain, the web server can correctly route traffic to the appropriate files based on the domain name requested. In this guide, we'll demonstrate how to configure Apache virtual hosts on an Ubuntu 14.04 VPS.
Have another answer? Share your knowledge.