简体   繁体   English

如何从主机将Web服务部署到虚拟服务器?

[英]How do I deploy a web service to a virtual server from the host?

all. 所有。 First of all I am sorry if this question is better for SuperUser, I couldn't tell. 首先,我无法回答这个问题是否对SuperUser更好。 If it is it would be great if someone could migrate it. 如果是这样的话,那么有人可以移植会很好。

So anyway, I'm building this service for SharePoint in Visual Studio 2008 with C#. 因此,无论如何,我正在使用C#在Visual Studio 2008中为SharePoint构建此服务。 Of course I need to be able to debug it to build it fast. 当然,我需要能够对其进行调试以快速构建它。 Unfortunately my OS is XP Pro which can't run SharePoint because it is not a server OS. 不幸的是,我的操作系统是XP Pro,因为它不是服务器操作系统,所以无法运行SharePoint。 Instead of reinstalling my OS (which would create other problems) I got Server 2003 + SharePoint Server 2007 up and running inside a virtual machine with Virtual PC. 我没有重新安装操作系统(这会带来其他问题),而是安装了Server 2003 + SharePoint Server 2007并在具有Virtual PC的虚拟机中运行。 Is there some sort of pipe I can create from Visual Studio that will let me test my service from within the virtual machine? 我可以从Visual Studio创建某种管道,让我从虚拟机中测试服务吗?

Thank you! 谢谢!

I guess I should add, these are the tools I have been given. 我想我应该补充,这些是我得到的工具。 At this time, reinstalling or getting new equipment/software is not an option. 目前,不能选择重新安装或获取新设备/软件。

This is definitely stackoverflow worthy. 这绝对是值得的stackoverflow。 It is a development process related question after all. 毕竟这是一个与开发过程有关的问题。

So you have two issues, deployment and debugging. 因此,您有两个问题,即部署和调试。

For deployment, there are really two ways to approach this. 对于部署,实际上有两种方法可以解决此问题。 One is that you create a real .wsp package that you can deploy/install/upgrade via the SharePoint provided mechanisms. 一种是创建一个真正的.wsp程序包,可以通过SharePoint提供的机制来部署/安装/升级。 You really should have this prepared since it is the way that your final code should be deployed. 您确实应该为此做好准备,因为这是部署最终代码的方式。 The trouble is that you can only perform the deploy/install/upgrade via a machine connected to the farm. 问题在于您只能通过连接到服务器场的计算机执行部署/安装/升级。 In this case it would be your VM. 在这种情况下,它将是您的VM。 In cases where I have had to work this way, I have scripted the creation of the .wsp and copied it to the server. 在必须以这种方式工作的情况下,我已编写了.wsp脚本并将其复制到服务器。 On the server is another script to do the deployment. 在服务器上是另一个脚本来进行部署。 Yes it is more steps than I would like but it does work and it is pretty mindless so it isn't too much of a hassle. 是的,它比我想要的要多得多,但是它确实有效,而且它完全没有脑子,因此也不会太麻烦。

The second approach would be the quicker, less correct way. 第二种方法是更快,更不正确的方法。 In this case if all you are doing is changing the code, then you just need to get your new DLL to replace the old one and bounce IIS. 在这种情况下,如果您要做的只是更改代码,则只需要获取新的DLL即可替换旧的DLL并启动IIS。 You might be able to do that all remotely via script fired from Visual Studio after build succeeds action. 在构建成功后,您可以通过从Visual Studio触发的脚本来远程完成所有操作。

As for debugging, you can certainly debug things remotely. 至于调试,您当然可以远程调试。 Look into tutorials on remotely debugging processes using Visual Studio. 查看有关使用Visual Studio进行远程调试过程的教程。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 是否可以在其他主机服务器上部署Java Web服务和SQL数据库? - Can I deploy Java web service and SQL database in different host server? 如何在云服务器中托管Web服务? - How to host the web service in cloud server? 如何在 glassfish 服务器中部署 web 应用程序和 web 服务 - how to deploy web application and web service in glassfish server 在服务器上托管SOAP Web服务 - Host a SOAP web service on a server 如何在将数据从 web 服务移动到 Sql Server 2005 时保留回车? - How do I retain carriage returns while moving data from a web service into Sql Server 2005? 如何在Web上部署Web服务 - how to deploy web service on the web 如何在Web服务安装期间更改默认的虚拟目录名称? - How do I change the default Virtual Directory name during a web service install? 如何将可在本地工作的Web服务(REST API,Java)上传到主机服务器 - How I upload my web Service(REST api, in java) that works locally to a host server 如何在Glass Fish Server / Apache Tomcat上部署Rest Web Service? - How to deploy Rest Web Service on Glass Fish Server/Apache Tomcat? 如何配置任何Web服务器以接受没有主机和绝对请求URIS的POST请求? - How do I configure ANY web server to accept POST requests that have No Host and absolute request URIS?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM