Deployed to solve the wrong path on the server LNMP pagoda panel created by the issue-based project development thinkphp

First, the environment and version:

Host: amazon aws EC2 host

System: Ubuntu 18.04.2 LTS (GNU / Linux 4.15.0-1039-aws x86_64)

Panel: pagoda Free Edition 6.9.5

Services: Nginx 1.16, PHP 7.2, MySQL 5.7.22 (running on the amazon of RDS, not by pagoda panel installation, this discussion does not involve database)

Program: ThinkPHP 5.0.24

Second, the deployment process

1. in the clouds open and start the host, do a little bit of necessary upgrades and small configuration (omitted find the host's website).

2. Log host installation pagoda panel (omitted pagoda find the official website).

3. Log pagoda panel, install operating environment:

I chose LNMP environment, select nginx version 1.16, PHP version 7.2, mysql does not tick, phpmyadmin not check, FTP check whether it's normal, then I'm used to select the "compile and install", although the installation will run slower but more fluid.

4. Create a website in the panel:

Configuring a good domain name and path information, and start the FTP, configure the login name and password, and then created directly.

Do not forget to resolve the domain name in advance.

5. Upload website:

I usually put the contents on the local PC folder of the project file is packaged zip, zip through FTP and then uploaded to the web root directory of the server. Then enter the pagoda panel file management module, find the archive directly extract. This action will save a lot of time to upload.

6. configure the site in the pagoda panel (key) :

Login Panel - Website - behind the corresponding site record "Settings":

1560399419(1)

Select a site in the directory layer to open the bomb - run directory - / public, save

image

Do not close the elastic layer, the code is written in pseudo-static:

location / {
    if (!-e $request_filename){
        rewrite  ^(.*)$  /index.php?s=$1  last;   break;
    }
}

image

Here you can turn off the playing floor, with direct access to try to resolve a good domain name, if still error, you can try to restart the sites and services.

that's it.

Guess you like

Origin www.cnblogs.com/chenqiang001/p/11015906.html