美文网首页我爱编程
laravel项目正式上线后需要做的操作

laravel项目正式上线后需要做的操作

作者: dongshixiao | 来源:发表于2018-03-26 18:31 被阅读0次

laravel项目正式想先后需要做的操作,关闭调试模式、生成配置缓存、路由缓存、生成编译文件。

.env APP_ENV=local 改成 APP_ENV=production
app_debug : false //关闭调试模式

php artisan config:cache //配置缓存,生成:bootstrap/cache/config.php
php artisan config:clear
php artisan route:cache //路由缓存,生成:bootstrap/cache/routes.php
php artisan route:clear
php artisan optimize //优化,生成编译文件;
php artisan clear-compiled  //仅在非调试环境下生成:bootstrap/cache/compiled.php

相关文章

网友评论

    本文标题:laravel项目正式上线后需要做的操作

    本文链接:https://www.haomeiwen.com/subject/nbaoqftx.html