Pre-loading your VM for SharePoint Development

Figured I would continue to bloat about using VMs with SharePoint development as some people have been reading my posting and AC's and been adjusting their environments.

A couple of things about my setup. My machine names are all named SPSDEV. If anyone knows why this is a problem, raise your hand now. Okay, times up. Yes, if you rename a server then your SharePoint will break. This is because the names of the content databases and various other config info is kept in the database and thus a rename will break this as the name of the server won't be known. There's a quick fix (which I don't follow myself but I'm *pretty* sure it works) and that's to just add the new name in your HOSTS file and have it point to 127.0.0.1. Again, I haven't done this myself as I go through the somewhat painful steps of really renaming a server. If you're into self-abuse, here are the instructions on doing this courtesy of Microsquishy.

The next thing is to get your image ready for copying and set everything up *before* you copy it. This is so when you launch it you won't have to install software and configure things that are important. So a few key things to do:

Desktop
The default desktop on servers is boring and I usually go in and add My Computer to it so I can quickly get to the Manage and Properties options. Your choice but it saves time.

Environment Variables
Personally I'm a kinda command line guy so when you launch the command prompt and type STSADM it should work. Well, this isn't a normally pathed location so add it. Right click on My Computer, choose the Advanced Tab, click on the Environment Variables button and add the bin folder of the 60 hive (you really don't want me to type that out do you?) to your path.

Shortcuts
I also put a couple of shortcuts on my desktop like a shortcut to the 60 hive folder. Handy for dragging files there and generally doing quick little tasks.

Tools
My favorite thing is tools so a few that you should include on every single solitary SharePoint setup you have:

  • SharePoint Explorer. The best thing since sliced bread as you can look at sites, see what is there and dig around in the properties that you can't get at through the Web UI. Invaluable. Best of all, it's free!
  • InstallAssemblies. Great tool from Blue Dog that you can launch and just add your SafeControl entries for your Web Parts and copy the files to the bin directory. Beats the heck out of running a CAB project and doing things by hand. Will also create a CAB file for you so...
  • SharePoint Configuration Analyzer. Nice tool that will tell you pretty much everything about your SharePoint setup and point out anything that's amiss (like assemblies not signed, missing templates, etc.)
  • CAML Builder. From U2U. A great tool to help you decipher CAML and do queries against your lists to see if what you're writing will work. Also contains an assembly that you can save your queries in Xml format and launch from your applications or Web Parts.

There are others (and people have huge lists of tools to have). These are just ones that I never leave home without. So remember to load up your image with your tools you need (Visual Studio 2003 and the Web Part Templates if you're going that route) and when you launch your VM for the first time, you'll be all set to go.

Enjoy.

1 Comment

  • Excellent choice of topics. I am also a fan of this type of developement work and I use this method to test the various "Free" webparts that are floating around out there before I throw it onto a Dev server ( for further user looks) and finally deploying to Production.

    My Setup involves 2 VM's One Server that runs pretty much everything and a desktop image which i use to test the client look and feel .



    Good Stuff.

Comments have been disabled for this content.