Publish the Commerce Engine

Current version: 8.2

Publishing represents activities associated with building and packaging the Sitecore Commerce Engine, with partner and customer extensions, into a package which can be deployed using any form supported by ASP.NET Core. There are multiple ways to publish the Sitecore Commerce Engine.

To publish to IIS, use the following instructions:

  1. Configure IIS.

  2. Install .NET Core Windows Server Hosting bundle.

  3. Configure the applications.

  4. Deploy.

  5. Configure the IIS website.

  6. Create a Data Protection Registry Hive.

For more information, go to https://docs.asp.net/en/latest/publishing/iis.html.

To publish to IIS using Web Deploy, use the following instructions:

  1. Configure the remote IIS Server to support ASP.NET Core.

  2. Create a publish profile.

  3. Customize the profile to support Web Deploy publish.

For more information, go to https://docs.asp.net/en/latest/publishing/iis-with-msdeploy.html.

To publish using Visual Studio, use the following instructions:

  1. Create a publish profile at Properties\PublishProfiles\profilename.pubxml. The publish profile is an MSBuild file.

  2. Create a PowerShell script at Properties\PublishProfiles\profilename.ps1.

  3. Call dotnet publish to gather the files to publish them to a temporary folder.

  4. Call a PowerShell script to pass in the properties from the publish profile, and from where the location that the dotnet publish placed the files to publish.

For more information about publishing and Azure, go to the following links:

The following are PowerShell samples of ASP.NET Core commands to publish the Sitecore Commerce Engine.

dotnet publish

Publishes in debug mode.

dotnet publish --configuration Release

Publishes in release mode, by default to this directory: C:\Src\Commerce.CommerceServer\Sdk\Sitecore.Commerce.Engine\bin\Release\net452\win7-x64\publish

dotnet build --build-profile

 

Additional information about publishing and running ASP.NET Core applications is available.

For more information about publishing and running ASP.NET Core Applications with IIS, go to: https://weblog.west-wind.com/posts/2016/Jun/06/Publishing-and-Running-ASPNET-Core-Applications-with-IIS

For more information on how web publishing in Visual Studio works, go to: https://docs.asp.net/en/latest/publishing/web-publishing-vs.html

Do you have some feedback for us?

If you have suggestions for improving this article,