Azure CD管道找不到构建工件

时间:2020-07-24 12:14:18

标签: azure azure-devops azure-web-app-service azure-pipelines-release-pipeline build-pipeline

下面是来自Azure发布管道的Azure错误日志。

2020-07-24T05:17:13.7712974Z ##[section]Starting: Deploy Azure App Service
2020-07-24T05:17:14.0464143Z ==============================================================================
2020-07-24T05:17:14.0465719Z Task         : Azure App Service deploy
2020-07-24T05:17:14.0469391Z Description  : Deploy to Azure App Service a web, mobile, or API app using Docker, Java, .NET, .NET Core, Node.js, PHP, Python, or Ruby
2020-07-24T05:17:14.0469849Z Version      : 3.163.5
2020-07-24T05:17:14.0470410Z Author       : Microsoft Corporation
2020-07-24T05:17:14.0470921Z Help         : https://aka.ms/azureappservicetroubleshooting
2020-07-24T05:17:14.0471274Z =============================================================================
2020-07-24T05:17:16.0650643Z Got connection details for Azure App Service:'XXXXX'
2020-07-24T05:17:17.6576087Z (node:764) Warning: Use Cipheriv for counter mode of aes-256-ctr
**2020-07-24T05:17:17.6627737Z ##[error]Error: No package found with specified pattern: D:\a\r1\a\Drop<br/>Check if the package mentioned in the task is published as an artifact in the build or a previous stage and downloaded in the current job.**
2020-07-24T05:17:22.9168975Z Successfully added release annotation to the Application Insight : XXXXX
2020-07-24T05:17:24.8686063Z Successfully updated deployment History at https://XXXXX.scm.azurewebsites.net/api/deployments/231595567842919
2020-07-24T05:17:24.8933576Z ##[section]Finishing: Deploy Azure App Service

P.S。我已经检查了构建管道,可以下载构建Artificats,但是它显示在警告下方。

[警告]目录'D:\ a \ 1 \ a'为空。不会添加任何东西来构建工件“放置”。

2 个答案:

答案 0 :(得分:0)

由于任务“发布构建工件”从$(build.artifactstaging目录)发布工件,因此我们需要添加任务“复制文件”以将文件**从$(system.defaultworkingdirectory)复制到$(build.artifactstagingdirectory) **。将我的构建复制到暂存目录。

答案 1 :(得分:0)

假设您已经解决了构建工件为空的问题,但是发布管道在public getCitta(): void { this.service.getCitta().subscribe(data => { this.citta = data?.citta; // After this point citta has a value }); console.log(this.citta); // this will print undefined } 任务中仍然存在问题。

如所提及的错误,“没有找到具有指定模式的软件包:D:\ a \ r1 \ a \ Drop”,您需要检查如何定义 package ,并尝试格式化{ {1}},而不是Azure App Service deploy

相关问题