我在 tfs2013 上创建了一个构建定义。当我对我的构建定义进行排队时,我收到有关不受信任的证书的错误。
C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v12.0\Web\Microsoft.Web.Publishing.targets (4270): Web deployment task failed. (Connected to the remote computer ("developertest") using the specified process ("Web Management Service"), but could not verify the server’s certificate. If you trust the server, connect again and allow untrusted certificates. Learn more at: http://go.microsoft.com/fwlink/?LinkId=221672#ERROR_CERTIFICATE_VALIDATION_FAILED.
我检查了帮助链接,它有 3 种方法可以解决它
- 在 msdeploy.exe 命令行中,您可以通过传递 -allowUntrusted 标志来执行此操作。
在 Visual Studio 2010 发布 UI 中,您可以选中“允许不受信任”
从 Visual Studio 2010 部署包(例如 MyApp.deploy.cmd),您可以传递 -allowUntrusted 标志
对于第一种和第三种方式,我不知道该怎么做 在第二种方式中,我在 vs2013 发布对话框中找不到 Allow untrusted
最佳答案
我将/p:AllowUntrustedCertificate=true 添加到 MsBuild 参数。它已解决
关于ssl - 如何解决不受信任的证书错误?(TFS2013 构建并部署到 IIS),我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/33842222/