doutan2111 2015-12-07 15:01
浏览 66
已采纳

使用本地存储库中的git生成错误,在Azure上部署Laravel

I am trying to deploy a new Laravel application to an Azure webapp from a local git repository. In the app settings I configured the following as is suggested for deploying laravel on Azure:

App Settings - SCM_REPOSITORY_PATH => D:\homeepository - SCM_TARGET_PATH => D:\home\site

Virtual Applications and Directories - / => site\public

Kudu - Composer installed as extension

However when I run git push repo master in the command line it runs fine but at the end this is what I see:

remote: > php artisan clear-compiled                                                 
remote: .............................................................................
.....................................................................................
...............................                                                      
remote:                                                                              
remote:                                                                              
remote:                                                                              
remote:   [Symfony\Component\Process\Exception\RuntimeException]                     
remote:                                                                              
remote:   Unable to kill the process                                                 
remote: Fatal error: Uncaught exception 'Symfony\Component\Process\Exception\RuntimeE
xception' with message 'Unable to kill the process' in phar://D:/home/SiteExtensions/
ComposerExtension/Commands/composer.phar/vendor/symfony/process/Process.php:779      
remote:                                                                              
remote: Stack trace:                                                                 
remote: #0 phar://D:/home/SiteExtensions/ComposerExtension/Commands/composer.phar/ven
dor/symfony/process/Process.php(173): Symfony\Component\Process\Process->stop()      
remote:                                                                              
remote: #1 [internal function]: Symfony\Component\Process\Process->__destruct()      
remote:                                                                              
remote: #2 {main}                                                                    
remote: install [--prefer-source] [--prefer-dist] [--dry-run] [--dev] [--no-dev] [--n
o-plugins] [--no-custom-installers] [--no-autoloader] [--no-scripts] [--no-progress] 
[-v|vv|vvv|--verbose] [-o|--optimize-autoloader] [-a|--classmap-authoritative] [--ign
ore-platform-reqs] [--] [<packages>]...                                              
remote:   thrown in phar://D:/home/SiteExtensions/ComposerExtension/Commands/composer
.phar/vendor/symfony/process/Process.php on line 779                                 
remote:                                                                              
remote: An error has occurred during web site deployment.                            
remote:                                                                              
remote:                                                                              
remote: Error - Changes committed to remote repository but deployment to website fail
ed.                                                                                  
To <url>                                                                           
 * [new branch]      master -> master 

The files are not in D:\home\site but are in the repository. If I use the default settings the files are deployed but I still get the error. However the response time of the site can be extremely slow over 10s sometimes. I am also wondering if this error is to blame. Has anyone deployed laravel on azure recently and had this problem?

  • 写回答

1条回答 默认 最新

  • dpg76975 2015-12-08 02:37
    关注

    There is no necessary to set these App settings to deploy laravel apps to Azure Web Apps via Git. And by default, the root directory of the web app on Azure is D:\home\site\wwwroot\, usually we don’t need to change it.

    You can refer to this answer of Deploy Laravel to Azure to get steps of deploying laravel app to Azure. Also if you need to expose public folder to public, you may refer to laravel 5.1 on windows azure web application.

    Especially, according your error message, it seems that you leverage several symfony packages, here is a similar thread on SO "Unable to kill the process" error with "php composer.phar install" on Azure, you can try the methods mentioned there. Otherwise, you can try to first delete cache files, then run the composer command.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥15 delta降尺度计算的一些细节,有偿
  • ¥15 Arduino红外遥控代码有问题
  • ¥15 数值计算离散正交多项式
  • ¥30 数值计算均差系数编程
  • ¥15 redis-full-check比较 两个集群的数据出错
  • ¥15 Matlab编程问题
  • ¥15 训练的多模态特征融合模型准确度很低怎么办
  • ¥15 kylin启动报错log4j类冲突
  • ¥15 超声波模块测距控制点灯,灯的闪烁很不稳定,经过调试发现测的距离偏大
  • ¥15 import arcpy出现importing _arcgisscripting 找不到相关程序