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 如何在scanpy上做差异基因和通路富集?
  • ¥20 关于#硬件工程#的问题,请各位专家解答!
  • ¥15 关于#matlab#的问题:期望的系统闭环传递函数为G(s)=wn^2/s^2+2¢wn+wn^2阻尼系数¢=0.707,使系统具有较小的超调量
  • ¥15 FLUENT如何实现在堆积颗粒的上表面加载高斯热源
  • ¥30 截图中的mathematics程序转换成matlab
  • ¥15 动力学代码报错,维度不匹配
  • ¥15 Power query添加列问题
  • ¥50 Kubernetes&Fission&Eleasticsearch
  • ¥15 報錯:Person is not mapped,如何解決?
  • ¥15 c++头文件不能识别CDialog