laradocker niginx配置问题

thinkwei
  • 458

laradock环境安装好之后配置了laradocker/nginx/sites/app.conf文件之后
访问网站后台之后是下面的页面 网站是用的ci框架 如何配置才能正常访问网站后台首页呀
image.png

回复
阅读 886
1 个回答
thinkwei
  • 458
✓ 已被采纳
location ~ \.php$ {
    # try_files $uri /index.php =404;
    fastcgi_pass php-upstream;
    fastcgi_index index.php;
    fastcgi_buffers 16 16k;
    fastcgi_buffer_size 32k;
    fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
    #fixes timeouts
    fastcgi_read_timeout 600;
    include fastcgi_params;
}

location /admin.php {
    fastcgi_pass php-upstream;
    fastcgi_param SCRIPT_FILENAME /var/www/your_directionary/admin.php;    
    fastcgi_param PATH_INFO $fastcgi_path_info;    
    fastcgi_split_path_info ^(.+\.php)(.*)$;    
    fastcgi_param PATH_TRANSLATED $document_root$fastcgi_path_info;    
    include fastcgi_params;
}
撰写回答
你尚未登录,登录后可以
  • 和开发者交流问题的细节
  • 关注并接收问题和回答的更新提醒
  • 参与内容的编辑和改进,让解决方法与时俱进
宣传栏