我面临着一个奇怪的问题。我使用Azure DevOps Pipeline Release部署了我的代码 - 它成功运行,但是代码没有反映在Azure Function App中。
这是我在做的事情:
D:\home\site\wwwroot
下找到已部署的zip文件部署日志:
Got service connection details for Azure App Service:'myFuncApp'
Updating App Service Application settings. Data: {"WEBSITE_RUN_FROM_PACKAGE":"1"}
Updated App Service Application settings and Kudu Application settings.
Package deployment using ZIP Deploy initiated.
Successfully deployed web package to App Service.
App Service Application URL: http://myFuncApp.azurewebsites.net
查看功能应用程序部署中心选项卡:
Deployed Successfully to production
Source Version 6d9c8340ba Build 20190411.1 Release: 3
功能应用程序端点正在工作,(抛出一个通用的欢迎页面)确认功能应用程序本身是健康的,但我无法访问我的API。
其他更新以下是.zip文件的结构,该文件作为Azure管道的zip部署的一部分上载到d:\home\data\SitePackages
:
/host.json
/package.json
/proxies.json
/package-lock.json
/func_name/index.js
/func_name/function.json
/node_modules/**
相同的代码在本地工作。
注意:当我转到Deployment Center选项卡时,我确实看到了此错误消息,但我认为这与通过Function App进行持续部署有关
We were unable to connect to the Azure Pipeline that is connected to this Web App. This could mean it has been removed from the Azure Dev Ops Portal. If this has happened, you can disconnect this pipeline and set up a new deployment pipeline.
请帮我。什么可能出错?
我终于能够排除故障了。 @ 4c74356b41指出我正确的方向,因为关键问题是包。
以下是问题:
Azure Functions
。因此,它正在压缩我的压缩文件。当我删除存档步骤时,避免了双重压缩,它开始工作。