LARAVEL5 Linux Installation

Source: Internet
Author: User

Laravel must php>5.4 support MCrypt.

from Https://github.com/overtrue/latest-laravel here to download the great God organized, decompression can be used


nginx pseudo-static:

server{listen 80; #listen  [::]:80;server_name laravel.zy62.com;index index.html  index.htm index.php default.html default.htm default.php;root  /home/wwwroot/ laravel.zy62.com/public;include other.conf; #error_page    404   /404.html; Location ~ .*\. (PHP|PHP5)?$        {             try_files  $uri  =404;             fastcgi_pass  unix:/tmp/php-cgi.sock;             fastcgi_index index.php;             include fcgi.conf;        }location  ~ .*\. (gif|jpg|jpeg|png|bmp|swf) ${expires      30d;} Location ~ .*\. (JS|CSS)? ${expires      12h;} if  (!-d  $request _filename)             {                 rewrite ^ /(. +)/$ /$1 permanent;            }             # removes trailing  " Index " from all controllers             if  ($request _uri ~* index/?$)              {                 rewrite ^/(. *)/index/?$ /$1 permanent;             }            # unless the request is for a valid file  (Image,  js, css, etc.), send to bootstrap             if  (!-e  $request _filename)              {                 rewrite ^/(. *) $ /index.php?/$1 last;                 break;             }access_log  /home/wwwlogs/laravel.zy62.com.log  access;}

include fcgi.conf;

fastcgi_param  script_filename     $document _root$fastcgi_script_name;fastcgi_ param  query_string        $query _string;fastcgi_param   request_method      $request _method;fastcgi_param  content_type         $content _type;fastcgi_param  content_length       $content _length;fastcgi_param  script_name        $ fastcgi_script_name;fastcgi_param  request_uri        $ request_uri;fastcgi_param  document_uri        $document _uri; fastcgi_param  document_root       $document _root;fastcgi_param   SERVER_PROTOCOL     $server _protocol;fastcgi_param  gateway_interface   cgi/1.1;fastcgi_param   server_software    nginx/$nginx _version;fastcgi_param  remote_addr          $remote _addr;fastcgi_param  remote_port          $remote _port;fastcgi_param  server_addr          $server _addr;fastcgi_param  server_port          $server _port;fastcgi_param  server_name         $server _name;# php only, required if php was built with -- enable-force-cgi-redirectfastcgi_param  redirect_status    200;



Error:an Another FPM instance seems to already listen On/tmp/php-cgi-714ms.com.sock


Workaround:

/ROOT/LNMP Reload


LARAVEL5 Linux Installation

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.