TFS ONPREMISE-软件包供稿-BuildAgent无法还原Nuget软件包:403

时间:2019-04-17 14:24:44

标签: tfs nuget nuget-package nuget-package-restore

我尝试将TFS内部部署与Package Feed作为NugetServer一起用于我的自定义软件包。

这是我所有配置设置的转储:

  • TFS服务器:版本16.122.27409.2
  • 在Push上设置的Task Nuget可以正常工作。
  • agentbuild用户帐户可以在浏览器中访问提要URL(https://xxx/team/_packaging/myfeedPackage/nuget/v3/index.jsonhttps://XXXXX/XXXX/_packaging/GUID/nuget/v3/index.json),并且可以检索完整的软件包列表。
  • 在供稿设置中将我的agentbuild帐户设置为“所有者”
  • 我的agentbuild帐户是Project Collection Build服务帐户和Project Collection Admin
  • 仅使用nuget.org即可正常工作。
  • 服务器Auth尚未激活基本身份验证
  • buildagent用户帐户在“软件包管理”的“用户”列表中
  • 我使用基本配置来使用提要;见下文: nugettask
  • 这是我的nuget.config nugetconfig 最后是我的错误。
      

    2019-04-17T12:14:15.8577145Z ## [section]开始:NuGet restore ***。sln   2019-04-17T12:14:15.8890019Z ======================================== =====================================   2019-04-17T12:14:15.8890019Z任务:NuGet   2019-04-17T12:14:15.8890019Z说明:还原,打包或推送NuGet程序包,或运行NuGet命令。支持NuGet.org和经过身份验证的提要,例如“软件包管理”和“ MyGet”。   2019-04-17T12:14:15.8890019Z版本:2.0.7   2019-04-17T12:14:15.8890019Z作者:微软公司   2019-04-17T12:14:15.8890019Z帮助:More Information   2019-04-17T12:14:15.8890019Z ======================================== =====================================   2019-04-17T12:14:17.0140203Z在缓存中找到工具:NuGet 4.0.0 x64   2019-04-17T12:14:17.0140203Z在缓存中找到工具:NuGet 4.0.0 x64   2019-04-17T12:14:17.0296711Z从工具缓存中解析:4.0.0   2019-04-17T12:14:17.0296711Z使用版本:4.0.0   2019-04-17T12:14:17.0296711Z在缓存中找到工具:NuGet 4.0.0 x64   2019-04-17T12:14:17.0452724Z [command] C:\ Windows \ system32 \ chcp.com 65001   2019-04-17T12:14:17.0609004Z活动代码页:65001   2019-04-17T12:14:17.4514520Z检测到NuGet版本4.0.0.2283 / 4.0.0   2019-04-17T12:14:17.4514520Z SYSTEMVSSCONNECTION存在true   2019-04-17T12:14:17.7483273Z将NuGet.config保存到临时配置文件中。   2019-04-17T12:14:17.7639506Z [命令] D:\ BuildAgents \ Dev-AgentCtrl-05_work_tool \ NuGet \ 4.0.0 \ x64 \ nuget.exe源代码添加-NonInteractive-名称a3fed2a3-b497-407d-a1b5-bb8f7dad0e33 -来源https://XXXXX/XXXX/_packaging/a3fed2a3-b497-407d-a1b5-bb8f7dad0e33/nuget/v3/index.json -ConfigFile D:\ BuildAgents \ Dev-AgentCtrl-05_work \ 48 \ Nuget \ tempNuGet_59927.config   2019-04-17T12:14:18.5765194Z成功添加了名称为:a3fed2a3-b497-407d-a1b5-bb8f7dad0e33的软件包源。   2019-04-17T12:14:18.5928735Z [command] D:\ BuildAgents \ Dev-AgentCtrl-05_work_tool \ NuGet \ 4.0.0 \ x64 \ nuget.exe源添加-NonInteractive-名称NuGetOrg-源https://api.nuget.org/v3/index.json- ConfigFile D:\ BuildAgents \ Dev-AgentCtrl-05_work \ 48 \ Nuget \ tempNuGet_59927.config   2019-04-17T12:14:19.3420745Z已成功添加名称为NuGetOrg的软件包源。   2019-04-17T12:14:19.3420745Z将NuGet.config保存到临时配置文件中。   2019-04-17T12:14:19.3576993Z [命令] D:\ BuildAgents \ Dev-AgentCtrl-05_work_tool \ NuGet \ 4.0.0 \ x64 \ nuget.exe恢复D:\ BuildAgents \ Dev-AgentCtrl-05_work \ 48 \ s \ MySuperPackage.Server.sln-详细-NonInteractive -ConfigFile D:\ BuildAgents \ Dev-AgentCtrl-05_work \ 48 \ Nuget \ tempNuGet_59927.config   2019-04-17T12:14:19.9202661Z NuGet版本:4.0.0.2283   2019-04-17T12:14:20.0295761Z MSBuild自动检测:使用来自'C:\ Program Files(x86)\ Microsoft Visual Studio \ 2017 \ Enterprise \ MSBuild \ 15.0 \ bin'的msbuild版本'15 .9.21.664'。使用选项-MSBuildVersion强制nuget使用特定版本的MSBuild。   2019-04-17T12:14:20.2014517Z MSBuild P2P超时[ms]:120000   2019-04-17T12:14:20.2170764ZC:\ Program Files(x86)\ Microsoft Visual Studio \ 2017 \ Enterprise \ MSBuild \ 15.0 \ bin \ msbuild.exe / t:GenerateRestoreGraphFile / nologo / nr:false / p:RestoreUseCustomAfterTargets = true / p:BuildProjectReferences = false / v:q /p:NuGetRestoreTargets="D:\BuildAgents\Dev-AgentCtrl-05_work_temp\NuGet-Scratch\jftfbyv1.wfk.targets“ / p:RestoreTaskAssemblyFile =” D:\ BuildAgents \ Dev -AgentCtrl-05_work_tool \ NuGet \ 4.0.0 \ x64 \ nuget.exe“ /p:RestoreGraphOutputPath="D:\BuildAgents\Dev-AgentCtrl-05_work_temp\NuGet-Scratch\toygjw1x.1vs.result” / p:ExcludeRestorePackageImports = true / p:RestoreRecursive = False / p:RestoreProjectFilterMode =排除列表/ p:RestoreContinueOnError = WarnAndContinue /p:RestoreGraphProjectInput="D:\BuildAgents\Dev-AgentCtrl-05_work\48\s\MySuperPackage.Server\MySuperPackage.Server.csproj;D :\ BuildAgents \ Dev-AgentCtrl-05_work \ 48 \ s \ MySuperPackage.Server.Tests \ MySuperPackage.Server.Tests.csproj; D:\ BuildAgents \ Dev-AgentCtrl-05_work \ 48 \ s \ MySuperPackage.Annuaire.IntegrationT ests \ MySuperPackage.Annuaire.IntegrationTests.csproj; D:\ BuildAgents \ Dev-AgentCtrl-05_work \ 48 \ s \ MySuperPackage.Server.Tools \ MySuperPackage.Server.Tools.csproj; D:\ BuildAgents \ Dev-AgentCtrl-05_work \ 48 \ s \ MySuperPackage.Permissions.IntegrationTests \ MySuperPackage.Permissions.IntegrationTests.csproj; D:\ BuildAgents \ Dev-AgentCtrl-05_work \ 48 \ s \ MySuperPackage.Mail.IntegrationTests \ MySuperPackage.Mail.IntegrationTests.csproj; D:\\ BuildAgents \ Dev-AgentCtrl-05_work \ 48 \ s \ MySuperPackage.Server.Testing \ MySuperPackage.Server.Testing.csproj; D:\ BuildAgents \ Dev-AgentCtrl-05_work \ 48 \ s \ MySuperPackage.Server.Data \ MySuperPackage.Server .Data.csproj; D:\ BuildAgents \ Dev-AgentCtrl-05_work \ 48 \ s \ MySuperPackage.Server.Data.Tests \ MySuperPackage.Server.Data.Tests.csproj; D:\ BuildAgents \ Dev-AgentCtrl-05_work \ 48 \ s \ MySuperPackage.RH.IntegrationTests \ MySuperPackage.RH.IntegrationTests.csproj;“ “ D:\ BuildAgents \ Dev-AgentCtrl-05_work_temp \ NuGet-Scratch \ jftfbyv1.wfk.targets”   2019-04-17T12:14:22.1545783Z恢复NuGet程序包MySuperPackage.Tools.Http.1.8.1。   2019-04-17T12:14:22.1545783Z恢复NuGet程序包MySuperPackage.Annuaire.Client.1.24.0-dev20190417-04。   2019-04-17T12:14:22.2014526Z缺少C:\ Users \ P-TF18-S-1BuildDev1.nuget \ packages \ MySuperPackage.tools.http \ 1.8.1 \ MySuperPackage.tools.http.1.8.1.nupkg   2019-04-17T12:14:22.2014526Z缺少C:\ Users \ P-TF18-S-1BuildDev1.nuget \ packages \ MySuperPackage.annuaire.client \ 1.24.0-dev20190417-04 \ MySuperPackage.annuaire.client.1.24。 0-dev20190417-04.nupkg   2019-04-17T12:14:22.6545739Z CredentialProvider.TeamBuild:“ D:\ BuildAgents \ Dev-AgentCtrl-05_work_tasks \ NuGetCommand_333b11bd-d341-40d9-afcf-b32d5ce6f23b \ 2.0.7 \ node_modules \ nuget-task-common \ NuGet \ CredentialProvider \ CredentialProvider.TeamBuild.exe” -uri https://XXXXX/XXXXXX/_packaging/a3fed2a3-b497-407d-a1b5-bb8f7dad0e33/nuget/v3/index.json -nonInteractive -verbosity详细   2019-04-17T12:14:22.6545739Z CredentialProvider.TeamBuild:URI前缀:   2019-04-17T12:14:22.6545739Z CredentialProvider.TeamBuild:https://tfs.XXXXXX/XXXXX/   2019-04-17T12:14:22.6545739Z CredentialProvider.TeamBuild:URI:https://tfs.XXXXXX/XXXXX/_packaging/a3fed2a3-b497-407d-a1b5-bb8f7dad0e33/nuget/v3/index.json   2019-04-17T12:14:22.6545739Z CredentialProvider.TeamBuild:重试:False   2019-04-17T12:14:22.6545739Z CredentialProvider.TeamBuild:匹配的前缀:https://tfs.XXXXXX/XXXXX/   2019-04-17T12:14:23.4045752Z CredentialProvider.TeamBuild:“ D:\ BuildAgents \ Dev-AgentCtrl-05_work_tasks \ NuGetCommand_333b11bd-d341-40d9-afcf-b32d5ce6f23b \ 2.0.7 \ node_modules \ nuget-task-common \ NuGet \ CredentialProvider \ CredentialProvider.TeamBuild.exe” -uri https://tfs.XXXXXX/XXXXX/_packaging/a3fed2a3-b497-407d-a1b5-bb8f7dad0e33/nuget/v3/index.json -isRetry -nonInteractive -verbosity详细   2019-04-17T12:14:23.4045752Z CredentialProvider.TeamBuild:URI前缀:   2019-04-17T12:14:23.4045752Z CredentialProvider.TeamBuild:https://tfs.XXXXXX/XXXXX/   2019-04-17T12:14:23.4045752Z CredentialProvider.TeamBuild:URI:https://tfs.XXXXXX/XXXXX/_packaging/a3fed2a3-b497-407d-a1b5-bb8f7dad0e33/nuget/v3/index.json   2019-04-17T12:14:23.4045752Z CredentialProvider.TeamBuild:重试:True   2019-04-17T12:14:23.4045752Z CredentialProvider.TeamBuild:匹配的前缀:https://tfs.XXXXXX/XXXXX/   2019-04-17T12:14:23.7327790Z CredentialProvider.TeamBuild:无法从您的项目集合中验证到https://tfs.XXXXXX/XXXXX/_packaging/a3fed2a3-b497-407d-a1b5-bb8f7dad0e33/nuget/v3/index.json,前缀= https://tfs.XXXXXX/XXXXX/   2019-04-17T12:14:25.1858247Z GET https://api.nuget.org/v3-flatcontainer/MySuperPackage.tools.http/1.8.1/MySuperPackage.tools.http.1.8.1.nupkg   2019-04-17T12:14:25.1858247Z GET https://api.nuget.org/v3-flatcontainer/MySuperPackage.annuaire.client/1.24.0-dev20190417-04/MySuperPackage.annuaire.client.1.24.0-dev20190417-04.nupkg   2019-04-17T12:14:25.4045771Z未找到https://api.nuget.org/v3-flatcontainer/MySuperPackage.annuaire.client/1.24.0-dev20190417-04/MySuperPackage.annuaire.client.1.24.0-dev20190417-04.nupkg 193ms   2019-04-17T12:14:25.4045771Z警告:找不到软件包'MySuperPackage.Annuaire.Client'的版本'1.24.0-dev20190417-04'。   2019-04-17T12:14:25.4045771ZC:\ Users \ P-TF18-S-1BuildDev1.nuget \ packages:在源代码'C上找不到软件包'MySuperPackage.Annuaire.Client.1.24.0-dev20190417-04': \ Users \ P-TF18-S-1BuildDev1.nuget \ packages \'。   2019-04-17T12:14:25.4045771Z https://tfs.XXXXXX/XXXXX/_packaging/a3fed2a3-b497-407d-a1b5-bb8f7dad0e33/nuget/v3/index.json:无法加载源https://tfs.XXXXXX/XXXXX/_packaging/a3fed2a3-b497-407d-a1b5-bb8f7dad0e33/nuget/v3/index.json的服务索引。   2019-04-17T12:14:25.4045771Z响应状态代码未指示成功:403(禁止)。   2019-04-17T12:14:25.4045771Z https://api.nuget.org/v3/index.json:在源'https://api.nuget.org/v3/index.json'上找不到包'MySuperPackage.Annuaire.Client.1.24.0-dev20190417-04'。   2019-04-17T12:14:25.4045771Z   2019-04-17T12:14:28.7483260Z未找到https://api.nuget.org/v3-flatcontainer/MySuperPackage.tools.http/1.8.1/MySuperPackage.tools.http.1.8.1.nupkg 3524ms   2019-04-17T12:14:28.7483260Z警告:找不到软件包'MySuperPackage.Tools.Http'的版本'1.8.1'。   2019-04-17T12:14:28.7483260ZC:\ Users \ P-TF18-S-1BuildDev1.nuget \ packages:在源代码C:\ Users \ P中找不到包'MySuperPackage.Tools.Http.1.8.1' -TF18-S-1BuildDev1.nuget \ packages \'。   2019-04-17T12:14:28.7483260Z https://tfs.XXXXXX/XXXXX/_packaging/a3fed2a3-b497-407d-a1b5-bb8f7dad0e33/nuget/v3/index.json:无法加载源https://tfs.XXXXXX/XXXXX/_packaging/a3fed2a3-b497-407d-a1b5-bb8f7dad0e33/nuget/v3/index.json的服务索引。   2019-04-17T12:14:28.7483260Z响应状态代码未指示成功:403(禁止)。   2019-04-17T12:14:28.7483260Z https://api.nuget.org/v3/index.json:在源代码“ https://api.nuget.org/v3/index.json”上找不到包“ MySuperPackage.Tools.Http.1.8.1”。   2019-04-17T12:14:28.7483260Z   2019-04-17T12:14:28.7795774Z   2019-04-17T12:14:28.7795774Zpackages.config项目中的错误   2019-04-17T12:14:28.7795774Z无法找到软件包'MySuperPackage.Annuaire.Client'的版本'1.24.0-dev20190417-04'。   2019-04-17T12:14:28.7795774Z   2019-04-17T12:14:28.7795774ZC:\ Users \ P-TF18-S-1BuildDev1.nuget \ packages:在源代码'C上找不到软件包'MySuperPackage.Annuaire.Client.1.24.0-dev20190417-04': \ Users \ P-TF18-S-1BuildDev1.nuget \ packages \'。   2019-04-17T12:14:28.7795774Z https://tfs.XXXXXX/XXXXX/_packaging/a3fed2a3-b497-407d-a1b5-bb8f7dad0e33/nuget/v3/index.json:无法加载源https://tfs.XXXXXX/XXXXX/_packaging/a3fed2a3-b497-407d-a1b5-bb8f7dad0e33/nuget/v3/index.json的服务索引。   2019-04-17T12:14:28.7795774Z响应状态代码未指示成功:403(禁止)。   2019-04-17T12:14:28.7795774Z https://api.nuget.org/v3/index.json:包'MySuperPackage.Annuaire.Client.1.24.0-dev20190417-04'在源'https://api.nuget.org/v3/index.json'上找不到。   2019-04-17T12:14:28.7795774Z无法找到软件包'MySuperPackage.Tools.Http'的版本'1.8.1'。   2019-04-17T12:14:28.7795774ZC:\ Users \ P-TF18-S-1BuildDev1.nuget \ packages:在源代码C:\ Users \ P中找不到包'MySuperPackage.Tools.Http.1.8.1' -TF18-S-1BuildDev1.nuget \ packages \'。   2019-04-17T12:14:28.7795774Z https://tfs.XXXXXX/XXXXX/_packaging/a3fed2a3-b497-407d-a1b5-bb8f7dad0e33/nuget/v3/index.json:无法加载源https://tfs.XXXXXX/XXXXX/_packaging/a3fed2a3-b497-407d-a1b5-bb8f7dad0e33/nuget/v3/index.json的服务索引。   2019-04-17T12:14:28.7795774Z响应状态代码未指示成功:403(禁止)。   2019-04-17T12:14:28.7795774Z https://api.nuget.org/v3/index.json:在源代码“ https://api.nuget.org/v3/index.json”上找不到包“ MySuperPackage.Tools.Http.1.8.1”。   2019-04-17T12:14:28.7795774Z使用的NuGet配置文件:   2019-04-17T12:14:28.7795774Z D:\ BuildAgents \ Dev-AgentCtrl-05_work \ 48 \ Nuget \ tempNuGet_59927.config   2019-04-17T12:14:28.7795774Z   2019-04-17T12:14:28.7795774Z使用的提要:   2019-04-17T12:14:28.7795774Z C:\ Users \ P-TF18-S-1BuildDev1.nuget \ packages \   2019-04-17T12:14:28.7795774Z https://tfs.XXXXXX/XXXXX/_packaging/a3fed2a3-b497-407d-a1b5-bb8f7dad0e33/nuget/v3/index.json   2019-04-17T12:14:28.7795774Z https://api.nuget.org/v3/index.json   2019-04-17T12:14:28.8265728Z ## [错误]错误:D:\ BuildAgents \ Dev-AgentCtrl-05_work_tool \ NuGet \ 4.0.0 \ x64 \ nuget.exe失败,返回码为1   2019-04-17T12:14:28.8265728Z ## [错误]包无法还原   2019-04-17T12:14:28.8265728Z ## [section]完成:NuGet restore ***。sln

1 个答案:

答案 0 :(得分:0)

我们找到了修补服务器tfs以更新3的“解决方案”:版本16.131.28601.4

现在一切正常...