Deploying a Laravel App on Azure

不打扰是莪最后的温柔 提交于 2019-12-12 02:09:23

问题


I am having a problem deploying my laravel 5.1 app, i don't have a customized deployment script... I already added the web.config file as specified in this tutorial

I have already installed composer. I already increased the composer timeout to 2000. The problem is that until now the deployment is still loading and it has been hours passed.

I'm using azure web app service.


回答1:


shouldn't take that long, can you disable the timeout, replace the "php artisan Optimize" with the "composer dump-autoload -o" in the composer.json - at post-install-cmd step if it still doesn't work, we should check the logs and see what's happening.




回答2:


Here is a workaround currently for deploying Laravel 5 applications to Azure Web Apps.

I removed the following commands under "post-install-cmd" scripts closure:

"php artisan clear-compiled",
"php artisan optimize"

Then Leverage Git to deploy to Azure Web App. For now, it will not throw the timeout processing exception when deploying.

Then install the Visual Studio online extension of your site the same as installing composer:

Click brower button to login the VSO which can modify and run console commands of your application:

click the "console" button open the cmdlet, run those command:

"php artisan clear-compiled",
"php artisan optimize"

And rest steps, you still can follow this tutorial



来源:https://stackoverflow.com/questions/35029959/deploying-a-laravel-app-on-azure

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!