1:上传代码到服务器
2:composer安装:composer install
3:拷贝.env.example文件成.env
4:给storage/logs文件夹读写的权限
5:访问域名:
加上public访问成功
没有指向项目的public目录
修改vhost下的域名文件,重新加载配置文件即可生效
location / {
try_files $uri $uri/ /index.php?$query_string;
}
lnmp集成环境 如果linux服务器下碰到错误:
Warning: require(): open_basedir restriction in effect. File(/home/wwwroot/vem/public/…/vendor/autoload.php) is not within the allowed path
修改:/usr/local/nginx/conf/fastcgi.conf配置中的open_basedir=NULL,重启nginx
composer 安装报错: The Process class relies on proc_open, which is not available on your PHP installation.
在php.ini中搜索disable_function找到proc_open删除即可
- 报错: No application encryption key has been specified
php artisan key:generate