问题已描述here https://developercommunity.visualstudio.com/content/problem/881015/no-certificate-found-with-the-supplied-thumbprint.html?childToView=1248035#.
太长了;
我有一个包含 WPF 应用程序和 WAP 项目的 .NET 解决方案存储库。我创建了一个管道来构建解决方案。管道定义 yaml 文件包含:
trigger:
- master
pool:
vmImage: 'windows-latest'
variables:
solution: '**/*.sln'
buildPlatform: 'Any CPU'
buildConfiguration: 'Release'
steps:
- task: NuGetToolInstaller@1
- task: NuGetCommand@2
inputs:
restoreSolution: '$(solution)'
- task: VSBuild@1
inputs:
solution: '$(solution)'
platform: '$(buildPlatform)'
configuration: '$(buildConfiguration)'
当管道在构建步骤中运行时,我收到错误:
##[error]C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\MSBuild\Microsoft\VisualStudio\v16.0\AppxPackage\Microsoft.AppXPackage.Targets(823,5): Error : No certificate found with the supplied thumbprint: 7FA3B996D434F774830FF22AE1A157751AFB419E
很难知道该问题的具体原因,因此请尝试以下操作:
- 正如错误消息所示,该错误很可能是由于您的证书造成的。尝试生成新证书或取消证书验证。
- 检查你的
.sln
文件。如果有PackageCertificateThumbprint
or PackageCertificateKeyFile
参数,检查其配置是否正确以及您是否已将正确的证书文件上传到相应的路径。或者尝试删除该参数看看问题是否解决。
- 确保代理
windows-latest
拥有您需要的所有.NET SDK版本以及您的项目需要引用的所有软件。如果没有,请使用任务或命令行下载它们。点击这个链接 https://github.com/actions/virtual-environments/blob/main/images/win/Windows2019-Readme.md查看安装在电脑上的软件windows-latest
agent.
- 尝试在本地运行构建项目。如果成功,请尝试使用自托管 Agent。点击这个文件 https://learn.microsoft.com/en-us/azure/devops/pipelines/agents/v2-windows?view=azure-devops#download-and-configure-the-agent了解详细步骤。
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)