TFS部署代理运行远程PowerShell问题

时间:2018-06-13 15:44:44

标签: continuous-deployment powershell-remoting tfs2017

我们有一个脚本语言应用程序。我想在开发服务器上进行CI部署。我在TFS中设置了部署定义,以便在远程计算机上执行步骤Run Powershell。但是遇到了我无法弄清楚的失败。我已经Enable-PSRemote -f在远程服务器dev-cf2016上了。我已经验证了像我一样远程进入TFS服务器,我可以运行:

Invoke-Cmd -computername dev-cf2016 -scriptblock {Get-ChildItem C:\}  

或任何其他命令。 TFSService帐户是TFS服务器上的本地管理员。

2018-06-12T20:36:19.5073933Z Deployment status for machine 'dev-cf2016:5986' : 'Failed'
2018-06-12T20:36:19.6011353Z 
2018-06-12T20:36:19.6011353Z 
2018-06-12T20:36:19.6011353Z ##[error]System.Management.Automation.RuntimeException: 
    Connecting to remote server dev-cf2016 failed with the following error message : 
    The client cannot connect to the destination specified in the request. Verify that the 
    service on the destination is running and is accepting requests. Consult the logs and 
    documentation for the WS-Management service running on the destination, most commonly 
    IIS or WinRM. If the destination is the WinRM service, run the following command on the 
    destination to analyze and configure the WinRM service: "winrm quickconfig". For more 
    information, see the about_Remote_Troubleshooting Help topic. 
---> System.Management.Automation.RuntimeException: Connecting to remote server 
    dev-cf2016 failed with the following error message : The client cannot connect to the 
    destination specified in the request. Verify that the service on the destination is
    running and is accepting requests. Consult the logs and documentation for the 
    WS-Management service running on the destination, most commonly IIS or WinRM. 
    If the destination is the WinRM service, run the following command on the destination 
    to analyze and configure the WinRM service: "winrm quickconfig". For more information, 
    see the about_Remote_Troubleshooting Help topic.

0 个答案:

没有答案