Unicorn for Sitecore Setting up Separate Core/Master Database Serialization

After getting the Unicorn sync to work I wanted to have separate folders for the Core and Master database items. It will keep things organized much better that way IMHO. After researching an asking around in Slack I came up with the following solution.

First  based on the Unicorn.Configs.Default.example I created two new configs. Unicorn.Configs.Core.config and Unicorn.Configs.Master.config.

coremasterconfig

In each file I changed the configuration name and description. Also it is very important that you add an entry for the physicalRootPath. This will override the default path.

This is what I did for the Core database. You will notice that the path ends in \Core.

 <configuration name="SitecoreTestSiteCore" description="This is my Sitecore Test Site. I am testing Unicorn and syncing CORE only.">
 <targetDataStore physicalRootPath="C:\Projects\SitecoreTestSite\src\WebApplication1\WebApplication1\App_Data\Unicorn\Serilization\Core" type="Rainbow.Storage.SerializationFileSystemDataStore, Rainbow" useDataCache="false" singleInstance="true" />

This is what I did for the Master database. You will notice that the path ends in \Master.

 <configuration name="SitecoreTestSiteMaster" description="This is my Sitecore Test Site. I am testing Unicorn and syncing Master only.">
 <targetDataStore physicalRootPath="C:\Projects\SitecoreTestSite\src\WebApplication1\WebApplication1\App_Data\Unicorn\Serilization\Master" type="Rainbow.Storage.SerializationFileSystemDataStore, Rainbow" useDataCache="false" singleInstance="true" />

After Initialization I did a sync. Look it is a cool looking unicorn.

unicorn

Now I have two separate directories for Core and Master files.

coremasterdirectory

Let me know if you have any questions.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s