#Formoreinformationonconfiguration,see:#*OfficialEnglishDocumentation:http://nginx.org/en/docs/#*OfficialRussianDocumentation:http://nginx.org/ru/docs/usernginx;worker_processesauto;error_log/var/log/nginx/error.log;pid/run/nginx.pid;events{worker_connections1024;}http{log_formatmain'$remote_addr-$remote_user[$time_local]"$request"''$status$body_bytes_sent"$http_referer"''"$http_user_agent""$http_x_forwarded_for"';access_log/var/log/nginx/access.logmain;sendfileon;tcp_nopushon;tcp_nodelayon;keepalive_timeout65;types_hash_max_size2048;include/etc/nginx/mime.types;default_typeapplication/octet-stream;#Loadmodularconfigurationfilesfromthe/etc/nginx/conf.ddirectory.#Seehttp://nginx.org/en/docs/ngx_core_module.html#include#formoreinformation.include/etc/nginx/conf.d/*.conf;server{listen80default_server;listen[::]:80default_server;server_name_;root/usr/share/nginx/html;#Loadconfigurationfilesforthedefaultserverblock.include/etc/nginx/default.d/*.conf;location/{}error_page404/404.html;location=/40x.html{}error_page500502503504/50x.html;location=/50x.html{}}}代码已贴上,环境是阿里云上的集成环境,如何解决(403页面并自动下载)
2 回答

www说
TA贡献1775条经验 获得超8个赞
/etc/nginx/default.d目录下的配置文件什么内容??不过不管是什么内容,都没有看到:location~\.php(.*){fastcgi_pass127.0.0.1:9000;.....}这样的代码,说明你没有设置如果碰到类似index.php或test.php这样的以.php(.*)结尾文件时的处理方式!当然他就会当成是不认识的文件进行下载了。
添加回答
举报
0/150
提交
取消