我有一个简单的VS2012 mvc网站。我已经构建了一个部署包,用于部署到IIS 8的本地实例。我可以从Visual Studio手动发布它(右键单击项目并点击发布),它运行良好。
我为该项目创建了TFS 2012构建。这成功编译并执行了我的单元测试。我的下一步是增强构建,以便它也部署网站 - 这是我遇到问题的地方。
我将以下内容添加为“MSBuild Arguments”:/ p:DeployOnBuild = True / p:DeployTarget = MsDeployPublish / p:DeployIisAppPath =“Default Web Site / TrainingCompany”/p:MsDeployServiceUrl=urlhere.com / p:username =用户名/ p:密码=密码
在构建之后,我在msbuild日志文件中获得以下内容:
Could not complete the request to remote agent URL 'http://urlhere.com:8172/msdeploy.axd?site=Default Web Site'.
The operation has timed out
at Microsoft.Web.Deployment.AgentClientProvider.GetHttpResponse(HttpWebRequest request)
at Microsoft.Web.Deployment.AgentClientProvider.PerformHeadRequestHelper(Boolean getVersionInfo, Version& maximumSupportedVersion, Version& minimumSupportedVersion)
at Microsoft.Web.Deployment.AgentClientProvider..ctor(DeploymentProviderContext providerContext, DeploymentBaseContext baseContext, String serverVersion)
at Microsoft.Web.Deployment.DeploymentManager.CreateObjectPrivate(DeploymentProviderContext providerContext, DeploymentBaseOptions baseOptions, DeploymentObject sourceObject, String serverVersion)
at Microsoft.Web.Deployment.DeploymentManager.CreateDestinationObject(DeploymentProviderOptions providerOptions, DeploymentBaseOptions baseOptions, DeploymentObject sourceObject, String serverVersion)
at Microsoft.Web.Deployment.DeploymentObject.SyncTo(DeploymentProviderOptions providerOptions, DeploymentBaseOptions baseOptions, DeploymentSyncOptions syncOptions)
at System.Dynamic.UpdateDelegates.UpdateAndExecuteVoid4[T0,T1,T2,T3](CallSite site, T0 arg0, T1 arg1, T2 arg2, T3 arg3)
at Microsoft.Web.Publishing.Tasks.VSMSDeployObject.SyncTo(VSMSDeployObject destObject, Object syncOptions, IVSMSDeployHost _host)
at System.Dynamic.UpdateDelegates.UpdateAndExecuteVoid4[T0,T1,T2,T3](CallSite site, T0 arg0, T1 arg1, T2 arg2, T3 arg3)
at Microsoft.Web.Publishing.Tasks.BaseMSDeployDriver.InvokeMSdeploySync()
at Microsoft.Web.Publishing.Tasks.BaseMSDeployDriver.SyncThruMSDeploy()
at Microsoft.Web.Publishing.Tasks.VSMSDeploy.Execute()
来自fiddler我尝试将以下内容作为GET请求执行 - 我的猜测是我应该得到一些东西,但我只是得到了504超时:
http://urlhere.com:8172/msdeploy.axd
有人可以告诉我可能做错了什么或我可以采取哪些额外措施进行问题排查?
答案 0 :(得分:0)
这可能是由于默认情况下在HTTPS上设置了WebDeploy,而不是HTTP。
试试https://urlhere.com:8172/msdeploy.axd,看看你怎么走。