Udostępnij za pośrednictwem


How to Package a Site

For the latest version of Commerce Server 2007 Help, see the Microsoft Web site.

When you package a site, you save your applications and settings in a single package file. For a list of the Microsoft Internet Information Services (IIS) properties that are included in the package, see How to View the IIS Properties for an Application, Folder, or File.

If you package a Commerce Server application whose IIS virtual directory contains child IIS applications, Site Packager will package the folders and files of the child applications. If you do not want the folders and files of the child applications included in the package, you will have to delete them after you unpack the parent Commerce Server application.

Site Packager does not package files in child virtual directories of the IIS application. If you must package files in child virtual directories, move the folders and files to child physical folders of the root folder of the IIS application before packaging your site.

Before you can package a site that has applications, for example, the Starter Site, on separate Web servers, you must add one of the Web servers to the other application. For example, if the Starter Site is installed on Computer A and SiteB is on Computer B, you can run Site Packager on Computer B to add it as a Web server for the Starter Site. Then you can package SiteB from Computer B. (Conversely, you could add Computer A to SiteB, and package the site there.) For more information, see How to Add a Web Server to an Application.

When you package a site, the default package will not include the extended Orders schema. If you want to use the extended Orders schema on other systems, you can do either of the following:

  • Execute the SQL script generated by the OrderMapping tool to create the database tables and stored procedures on your other systems.

  • Append the SQL file generated by the OrderMapping tool with the lower part of the Requisition.sql file, starting with the Requisition_Static.sql comment. Replace the Requisition.sql file located at %commerce_server_root%\Sdk\Samples\SiteCreate\ with this SQL file, and then unpack your site package. This will create the extended schema when you unpack your site package.

Note

You must use the /s option to generate the extended schema. The SQL generated will drop and re-create the tables in the transaction database.

Note

Not all the sites on your system may use the extended schema. You should restore the Requisition.sql file to its original state after you create your site package.

Note

You cannot package your Orders data. To migrate the Commerce Server 2007 schema, you must use the Upgrade Wizard to migrate the Orders data from an existing database.

For more information, see How to Generate SQL Tables and Stored Procedures for Orders Mapped Storage.

To package a site

  1. Click Start, point to Programs, point to Commerce Server 2007 , point to Tools, and then click Site Packager.

  2. On the Welcome to the Commerce Server Site Packager page, select Package an existing site, and then click Next.

  3. On the Package Site page, do the following:

    Use this

    To do this

    Site to package

    Select the site that you want to package from the list of available sites.

    Package file to create

    Type the name of the package file that you want to create, or click Browse.

    If you clicked Browse, in the Save As dialog box, locate the folder that contains the package file that you want to create, select the file, and then click Save.

  4. On the Package Site page, click Next.

  5. If the Profiles resource was added to the site that you are packaging, the Profiling System page appears. On the Profiling System page, do the following:

    Use this

    To do this

    Schema definition scripts

    To pack the profile definitions, use SQL Server Enterprise Manager to export the definitions (schema) from the SQL database to a .sql file, and then specify the name of that file here.

    When you unpack your site, you will specify this file so the definitions will be unpacked into the Profiles tables in the runtime data stores (the SQL tables that store the data for the user, address, organization, and more).

    For more information, see How to Run Site Packager from the Command Line.

    Data population scripts

    To pack the profile data stored in the Profiles database, use SQL Server Enterprise Manager to export the profile data from the SQL database to a .sql file, and then specify the name of that file here.

    When you unpack your site, you will specify that .sql file to populate your Profiles tables in the runtime data stores (the SQL tables that store the data for the user, address, organization, and more).

    For information about how to use scripts with site packager, see How to Use Scripts with Site Packager.

  6. Click OK.

  7. On the Packaging is complete! page, to review the list of events in the Site Packager log file, click View Log File.

  8. Click Finish to close Site Packager.

See Also

Other Resources

Managing Site Packages