Has there been an updated tutorial for installing LEMP on Ubuntu 14.04 in the past year?

Hi All, As the title suggests, I’m wondering if someone can tell me if there has been an updated tutorial for installing LEMP on Ubuntu 14.04 within the past year?

I’m a total n00b, but havent done too bad… well… until I got to step 4 and the highlighted text for the server blocks part, looked quite different to what I have to work with in putty. At the changes marked in red text below section of section 4 in the tutorial, I just become confused, because what I’m showing in putty has a lot of other bits, such as this…

# Only for nginx-naxsi used with nginx-naxsi-ui : process denied requests
        #location /RequestDenied {
        #       proxy_pass;

        #error_page 404 /404.html;

        #pass the PHP scripts to FastCGI server listening on
        #redirect server error pages to the static page /50x.html
        #error_page 500 502 503 504 /50x.html;
        #location = /50x.html {
        #       root /usr/share/nginx/html;

        # pass the PHP scripts to FastCGI server listening on

I wasn’t that confident as I was editing it, that it was going to work, obviously due to the differences, and it was confirmed after I entered the info.php text and went to test my site with the /info.php url that something was wrong, because instead of displaying the page generated by PHP with info about my server, instead it just instantly downloaded a .php file to my downloads folder on my pc.

This was the last step of getting my LEMP stack all loaded up and I really didn’t want to ask for support, but Ive been trying for hours to fix it to no avail, and I am fairly confident it is just the differences in step 4 that is my issue. The tutorial does date back to APR 25 2014, so as I mentioned earlier, I’m wondering if there has perhaps been an update to Nginx and that is why the server blocks in the tutorial, look different to what I am looking at in putty?

Any help would be appreciated.

Many thanks.

Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Thank you for your answer asb. All sorted. :)

In the LEMP on Ubuntu 14.04 tutorial, the default Nginx configuration shown is strips out commented lines to make it more readable:

Currently, with the comments removed, the Nginx default server block file looks like this:

server {
   listen 80 default_server;
   listen [::]:80 default_server ipv6only=on;

   root /usr/share/nginx/html;
   index index.html index.htm;

   server_name localhost;

   location / {
       try_files $uri $uri/ =404;

Lines that begin with “#” are comments. Anything that follows the “#” sign is ignored.