tags:

views:

51

answers:

2

I have a web part that I have been deploying to Server A. I now have a new SharePoint environment I would like to deploy my web part to (Server B). How can I set the web part solution to deploy to Server B rather than Server A? I have done this before but cannot find the place to do it.

Thanks.

+1  A: 

To Deploy from Visual studio, VS needs to be installed on the server you're deploying to. To change the site you're deploying to for development/debugging purposes is a property on the project file in VS.

Shane

Shaneo
I tried changing the csproj.user file to point to the new server and it still deployed to the old server. Any ideas why this would be?
Josh
Okay, I got it... I am now getting this error: Error 1 Error occurred in deployment step 'Recycle IIS Application Pool': Cannot connect to the SharePoint site: http://server/realestate/. Make sure that this is a valid URL and the SharePoint site is running on the local computer. If you moved this project to a new computer or if the URL of the SharePoint site has changed since you created the project, update the Site URL property of the project. 0 0 Is this probably because VS2010 is not installed on the SharePoint server?
Josh
Yes - if you need to deploy to a different server from Visual studio then Visual Studio needs to be on that server - items need to be copied into the hive and the GAC and an iisreset needs to be called.If your new server isn't a development server then use stsadm or powershell to deploy your WSP. No amount of changing a csproj file will allow you to remotely deploy from visual studio.
Shaneo
A: 

In order to deploy to a remote SP application, I recommend using PowerShell scripts that are run on the remote server. That is what I did, and it works well. Much easier than stsadm.

Josh