- Now it is time to create a solution package to move this entire solution of WSS components from your development machine into a staging environment or a production environment. The first thing you need to do uninstall and remove all the components from your development machine. Start up a command prompt and run the following batch file to reverse everything that was done by Install.bat.
C:\HOL\SharePointSolutions\Lab\Uninstall.bat
- Once you have run Uninstall.bat, you should be able to verify that the Lab2 feature is no longer activated or installed. You can do this by going to the Site Feature management page (/_layouts/ManageFeatures.aspx) and verifying that the Lab2 feature is not available for activation.
- Now look at the files inside the Solution folder of the current Visual Studio project and locate the two files named manifest.xml and cab.ddf. You will not be modifying these files in this exercise, but just looking at them. Once you have seen what is inside, you will then run batch files to build and deploy the solution package.
- First, look at the manifest.xml that will be added into the solution package.
- Next, look at what is inside the cab.ddf file.
- Now you have seen the two main files used to build a solution package. The cab.ddf file is used as input to MAKECAB.EXE to create a solution package named Lab2.wsp. The manifest.xml file is included inside the solution package and this file acts as the main manifest used by the WSS installer during solution package deployment.
- Bring up a command prompt navigate to the following directory.
- Run the batch file named CreateSolutionPackage.cmd to build Lab2.wsp. The contents of this batch file looks like this.
- Run the batch file named InstallSolutionPackage.cmd to install Lab2.wsp into the farm-scoped solution package store. The contents of this batch file looks like this.
- Run the batch file named DeploySolutionPackage.cmd to deploy the solution package. The contents of this batch file looks like this.
- Now, it’s time to make sure everything has been installed correctly and that your solution works after the solution package has been deployed. Navigate to Site Feature management page (/_layouts/ManageFeatures.aspx). Ensure you Lab2 feature is there and can be activated. Once you have activated it, test out the menu items and custom application pages to make sure they work.
- If you are interested, go through the steps of retracting the solution package as well. Start by deactivating the Lab2 feature in the current site and then run the batch file named DeploySolutionPackage.cmd which contains the follow command-line instructions.
|
See all the reviews