jubiki
By:
jubiki

How do I configure LEMP (Ubuntu 16.04) for Laravel 5.4?

February 7, 2017 4k views
LEMP Applications Ubuntu 16.04

Hello,

I did a basic one-click app install for LEMP (ubuntu 16.04). I was wondering if there was a tutorial on how to set it up for Laravel 5.4? I've found it for Ubuntu LAMP 14.04, but not for 16.04. Does anyone know where I can find a reliable source to get this done?

5 Answers

@jubiki

The overall gist of the guide here:

https://www.digitalocean.com/community/tutorials/how-to-install-laravel-with-an-nginx-web-server-on-ubuntu-14-04

... is pretty much the same for 16.04. The one section you would want to skip is the one regarding the creation of a swap file. This isn't recommended now, so it's safe to overlook that section.

by Justin Ellingwood
Laravel is an easy to use, modern framework for the PHP programming language. In this guide, we will demonstrate how to install Laravel with an Nginx web server on an Ubuntu 14.04 server instance.

I've tried that tutorial, and it didn't help me. I still get the default blue screen.

@jubiki
I have recently made a gist for configuring the latest laravel 5.4 on LEMP,follow the link here

https://gist.github.com/naveenyagati/5deec8fc40a2faaff20c629362dddf39

I figured it out, maybe LEMP 16.04 doesn't use the /etc/nginx/sites-available/default anymore. So, I tried editing this file instead.

sudo nano /etc/nginx/sites-enabled/digitalocean

Then, whooah! It worked :)

Reference:
https://www.digitalocean.com/community/tutorials/how-to-move-an-nginx-web-root-to-a-new-location-on-ubuntu-16-04

On Ubuntu, by default, the Nginx web server stores its documents in /var/www/html, which is typically located on the root filesystem with rest of the operating system. Sometimes, though, it’s helpful to move the document root to another location, such as a separate mounted...
Have another answer? Share your knowledge.