Nginx环境下配置webman框架的端口为80
server
{
listen 80;
#listen [::]:80;
server_name bztp.shyouhan.com ;
index index.html index.htm index.php default.html default.htm default.php;
root /home/wwwroot/bztp.shyouhan.com/public;
include rewrite/other.conf;
#error_page 404 /404.html;
# Deny access to PHP files in specific directory
#location ~ /(wp-content|uploads|wp-includes|images)/.*\.php$ { deny all; }
include enable-php-pathinfo.conf;
location ~ .*\.(gif|jpg|jpeg|png|bmp|swf)$
{
expires 30d;
}
location ~ .*\.(js|css)?$
{
expires 12h;
}
location ~ /.well-known {
allow all;
}
location ~ /\.
{
deny all;
}
location ^~ / {
proxy_pass http://bztp.shyouhan.com:8788/; # 注:proxy_pass的结尾有/, -> 效果:会在请求时将/api/*后面的路径直接拼接到后面
}
access_log /home/wwwlogs/bztp.shyouhan.com.log;
}