在Visual Studio Team Services的路径中找不到curl [英] curl was not found in the path Visual Studio Team Services

查看:450
本文介绍了在Visual Studio Team Services的路径中找不到curl的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在Visual Studio Team Services中使用托管代理进行版本管理。我在上周工作的发布商定义中有一个 cURL上传文件任务,过去几周我已经完成了几次成功的部署。



今天我从相同的发布定义创建了一个新版本,并且在 cURL上传文件任务中收到以下错误。

  2016-03-31T08:56:43.4253012Z ## [debug] curl = null 
2016-03-31T08:56:43.4263027Z ## [error]路径。
2016-03-31T08:56:43.4303022Z ## [debug]任务结果:失败
2016-03-31T08:56:43.4313025Z返回码:1



我已检查托管代理的系统功能,并列出 curl C:\Program Files(x86)\Git\\ \\ bin \curl.exe 作为其中一个。



任何人都有任何想法为什么这突然开始失败?

解决方案

首先,对不起。我与产品团队,我们已经确认这是一个回归在我们身边。 cURL仍然在盒子上,但它不再在路径中。我们正在努力让这个固定在我们的尽头,但它可能需要一两天。同时,我们建议您执行以下操作:


  1. 在curl任务之前,创建一个新的PowerShell任务

  2. 将任务类型更改为内联脚本

  3. 将内联脚本输入更改为以下内容:

echo## vso [task.setvariable variable = PATH;] $ env:PATH; C:\Program Files\Git\usr\\ \\bin


  1. 保存并排队新建建筑。






更新:我们已解决此问题。解决方法应该不再需要。


I'm using the Hosted Agent for release management in Visual Studio Team Services. I have a cURL Upload Files task on my release definition which was working last week and I've had several successful deployments over the past weeks.

Today I created a new release from the same release definition and I am receiving the following error on the cURL Upload Files task.

2016-03-31T08:56:43.4253012Z ##[debug]curl=null
2016-03-31T08:56:43.4263027Z ##[error]curl was not found in the path.
2016-03-31T08:56:43.4303022Z ##[debug]task result: Failed
2016-03-31T08:56:43.4313025Z Return code: 1

I have checked the System Capabilities on the Hosted Agent and it lists curl C:\Program Files (x86)\Git\bin\curl.exe as one of them.

Any one have any ideas why this has suddenly started failing?

解决方案

First, sorry about this. I'm with the product team and we’ve confirmed this is a regression on our side. cURL is still on the box but it is no longer in the path. We’re working on getting this fixed on our end but it’ll likely take a day or two. In the meantime, we’d recommend doing the following:

  1. Before your curl task, create a new powershell task
  2. Change the type of the task to be an "Inline Script"
  3. Change the Inline Script input to be the following:

echo "##vso[task.setvariable variable=PATH;]$env:PATH;C:\Program Files\Git\usr\bin"

  1. Save and queue a new build.


UPDATE: We've fixed this issue now. The workaround should be no longer necessary.

这篇关于在Visual Studio Team Services的路径中找不到curl的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆