thinkphp5 nginx配置
余温
2018年03月12日 14时09分
php
log_format 5.5sit.com '$remote_addr - $remote_user [$time_local] "$request" ' '$status $body_bytes_sent "$http_referer" ' '"$http_user_agent" $http_x_forwarded_for'; server { listen 80 default_server; server_name 5.5sit.com; #if ($host != '5.5sit.com' ) { # rewrite ^/(.*)$ http://5.5sit.com/$1 permanent; #} index index.html index.htm index.php default.html default.htm default.php; root /home/wwwroot/default/tp/public; #include other.conf; include enable-php7.1.conf; location /{ if (!-e $request_filename) { rewrite ^/(.*)$ /index.php?s=/$1 last; break; } } location /nginx_status { stub_status on; access_log off; } location ~ .*\.(gif|jpg|jpeg|png|bmp|swf)$ { expires 30d; } location ~ .*\.(js|css)?$ { expires 12h; } location ~ /.well-known { allow all; } location ~ /\. { deny all; } access_log /home/wwwlogs/5.5sit.com.log 5.5sit.com; }
上一篇:
ThinkPHP3.2.3分页样式自定义
下一篇:
laravel5 发送邮件
请登陆后评论
{{vo.time}} 回复