Create a gist now

Instantly share code, notes, and snippets.

What would you like to do?
The following script imports the specified Sitecore Role configuration csv and automatically enables or disables the configs.
Product Filepath Filename DefaultExtension Provider CD CM PRC CMP RPT
Platform \website\ Web.config config Enable Enable Enable Enable Enable
Platform \website\App_Config\ Commands.config config Enable Enable Enable Enable Enable
Platform \website\App_Config\ ConnectionStrings.config config Enable Enable Enable Enable Enable
Platform \website\App_Config\ ConnectionStringsOracle.config config Enable Enable Enable Enable Enable
Platform \website\App_Config\ FieldTypes.config config Enable Enable Enable Enable Enable
Platform \website\App_Config\ Icons.config config Enable Enable Enable Enable Enable
Platform \website\App_Config\ LanguageDefinitions.config config Enable Enable Enable Enable Enable
Platform \website\App_Config\ MimeTypes.config config Enable Enable Enable Enable Enable
Platform \website\App_Config\ Portraits.config config Enable Enable Enable Enable Enable
Platform \website\App_Config\ Prototypes.config config Enable Enable Enable Enable Enable
Platform \website\App_Config\ Sitecore.config config Enable Enable Enable Enable Enable
Platform \website\App_Config\ XamlSharp.config config Enable Enable Enable Enable Enable
SPEAK \website\App_Config\Include 001.Sitecore.Speak.Important.config config Disable Enable Disable Enable Disable
Platform \website\App_Config\Include DataFolder.config config Enable Enable Enable Enable Enable
Platform \website\App_Config\Include EventHandler.config.example example NA NA NA NA NA
Platform \website\App_Config\Include ForwardingSecurityEvents.config.example example NA NA NA NA NA
Platform \website\App_Config\Include ja-JP.config.example example NA NA NA NA NA
Platform \website\App_Config\Include LiveMode.config.example example NA NA NA NA NA
Platform \website\App_Config\Include ScalabilitySettings.config.example example NA NA NA NA NA
Marketing Foundation \website\App_Config\Include Sitecore.Analytics.Automation.TimeoutProcessing.config config Disable Enable Disable Enable Disable
Marketing Foundation \website\App_Config\Include Sitecore.Analytics.Compatibility.config config Enable Enable Enable Enable Enable
Marketing Foundation \website\App_Config\Include Sitecore.Analytics.config config Enable Enable Enable Enable Enable
Marketing Foundation \website\App_Config\Include Sitecore.Analytics.ExcludeRobots.config config Enable Disable Disable Disable Disable
Marketing Foundation \website\App_Config\Include Sitecore.Analytics.MarketingTaxonomy.config config Enable Enable Enable Enable Enable
Marketing Foundation \website\App_Config\Include Sitecore.Analytics.MarketingTaxonomyCD.config.disabled disabled Enable Disable Disable Disable Disable
Marketing Foundation \website\App_Config\Include Sitecore.Analytics.Model.config config Enable Enable Enable Enable Enable
Marketing Foundation \website\App_Config\Include Sitecore.Analytics.MongoDb.config config Enable Enable Enable Enable Enable
Marketing Foundation \website\App_Config\Include Sitecore.Analytics.Oracle.config.disabled disabled Disable Disable Disable Disable Disable
Marketing Foundation \website\App_Config\Include Sitecore.Analytics.Outcome.config config Enable Enable Enable Enable Enable
Marketing Foundation \website\App_Config\Include Sitecore.Analytics.Processing.Aggregation.config config Disable Enable Enable Enable Disable
Marketing Foundation \website\App_Config\Include Sitecore.Analytics.Processing.Aggregation.ProcessingPools.config config Enable Enable Enable Enable Enable
Marketing Foundation \website\App_Config\Include Sitecore.Analytics.Processing.Aggregation.Services.config config Disable Disable Enable Enable Disable
Marketing Foundation \website\App_Config\Include Sitecore.Analytics.Processing.config config Disable Enable Enable Enable Disable
Marketing Foundation \website\App_Config\Include Sitecore.Analytics.Processing.Services.config config Disable Disable Enable Enable Disable
Marketing Foundation \website\App_Config\Include Sitecore.Analytics.Reporting.config config Disable Enable Disable Enable Enable
Marketing Foundation \website\App_Config\Include Sitecore.Analytics.Tracking.Aggregation.config config Enable Disable Disable Disable Disable
Marketing Foundation \website\App_Config\Include Sitecore.Analytics.Tracking.config config Enable Enable Disable Enable Disable
Marketing Foundation \website\App_Config\Include Sitecore.Analytics.Tracking.Database.config config Enable Disable Disable Disable Disable
Marketing Foundation \website\App_Config\Include Sitecore.Analytics.Tracking.Database.ScaledCM.config.disabled config Enable Disable Disable Enable Disable
Marketing Foundation \website\App_Config\Include Sitecore.Analytics.Tracking.Outcome.config config Enable Enable Enable Enable Enable
Marketing Foundation \website\App_Config\Include Sitecore.Analytics.Tracking.RobotDetection.config config Enable Disable Disable Disable Disable
Platform \website\App_Config\Include Sitecore.AntiCsrf.config config Enable Enable Disable Enable Disable
AppCenter \website\App_Config\Include Sitecore.Apps.TagInjection.config config Enable Enable Enable Enable Enable
Platform \website\App_Config\Include Sitecore.Buckets.config config Enable Enable Disable Enable Disable
Platform \website\App_Config\Include Sitecore.Buckets.WarmupQueries.config.example example NA NA NA NA NA
Commerce \website\App_Config\Include Sitecore.Commerce.config config Enable Enable Enable Enable Enable
Commerce \website\App_Config\Include Sitecore.Commerce.ExperienceProfile.ReportingServer.config config Enable Enable Enable Enable Enable
Marketing Foundation \website\App_Config\Include Sitecore.ContentSearch.Analytics.config config Base Enable Enable Enable Enable Enable
Platform - Search \website\App_Config\Include Sitecore.ContentSearch.config config Enable Enable Enable Enable Enable
Platform - Search \website\App_Config\Include Sitecore.ContentSearch.DefaultConfigurations.config config Enable Enable Enable Enable Enable
Platform - Search \website\App_Config\Include Sitecore.ContentSearch.Lucene.DefaultIndexConfiguration.config config Lucene Enable Enable Enable Enable Enable
Marketing Foundation \website\App_Config\Include Sitecore.ContentSearch.Lucene.Index.Analytics.config config Lucene Enable Enable Enable Enable Enable
Platform - Search \website\App_Config\Include Sitecore.ContentSearch.Lucene.Index.Core.config config Lucene Enable Enable Enable Enable Enable
Platform - Search \website\App_Config\Include Sitecore.ContentSearch.Lucene.Index.Master.config config Lucene Disable Enable Enable Enable Enable
Platform - Search \website\App_Config\Include Sitecore.ContentSearch.Lucene.Index.Web.config config Lucene Enable Disable Disable Disable Disable
Platform - Search \website\App_Config\Include Sitecore.ContentSearch.Lucene.Indexes.Sharded.Core.config.example example Lucene Disable Disable Disable Disable Disable
Platform - Search \website\App_Config\Include Sitecore.ContentSearch.Lucene.Indexes.Sharded.Master.config.example example Lucene Disable Disable Disable Disable Disable
Platform - Search \website\App_Config\Include Sitecore.ContentSearch.Lucene.Indexes.Sharded.Web.config.example example Lucene Disable Disable Disable Disable Disable
Platform - Search \website\App_Config\Include Sitecore.ContentSearch.Solr.DefaultIndexConfiguration.config.example example Solr Enable Enable Enable Enable Enable
Marketing Foundation \website\App_Config\Include Sitecore.ContentSearch.Solr.Index.Analytics.config.example example Solr Enable Enable Enable Enable Enable
Platform - Search \website\App_Config\Include Sitecore.ContentSearch.Solr.Index.Core.config.example example Solr Disable Enable Disable Enable Disable
Platform - Search \website\App_Config\Include Sitecore.ContentSearch.Solr.Index.Master.config.example example Solr Disable Enable Disable Enable Disable
Platform - Search \website\App_Config\Include Sitecore.ContentSearch.Solr.Index.Web.config.example example Solr Enable Disable Disable Disable Disable
Platform - Search \website\App_Config\Include Sitecore.ContentSearch.VerboseLogging.config.example example NA NA NA NA NA
Platform \website\App_Config\Include Sitecore.DefaultLanguage.config config Enable Enable Enable Enable Enable
Platform \website\App_Config\Include Sitecore.Diagnostics.config config Enable Enable Enable Enable Enable
Experience Editor \website\App_Config\Include Sitecore.ExperienceEditor.config config Enable Enable Enable Enable Enable
Experience Editor \website\App_Config\Include Sitecore.ExperienceEditor.Speak.Requests.config config Disable Enable Enable Enable Enable
Experience Editor \website\App_Config\Include Sitecore.ExperienceExplorer.config config Enable Enable Enable Enable Enable
Experience Editor \website\App_Config\Include Sitecore.ExperienceExplorer.Speak.Requests.config config Disable Enable Enable Enable Enable
Platform - Item Web API \website\App_Config\Include Sitecore.ItemWebApi.config config Enable Enable Enable Enable Enable
Platform \website\App_Config\Include Sitecore.JSNLog.config config Enable Enable Enable Enable Enable
Platform \website\App_Config\Include Sitecore.LanguageFallback.config config Enable Enable Enable Enable Enable
Marketing Foundation \website\App_Config\Include Sitecore.Marketing.Client.config config Disable Enable Enable Enable Enable
Marketing Foundation \website\App_Config\Include Sitecore.Marketing.config config Enable Enable Enable Enable Enable
Marketing Foundation \website\App_Config\Include Sitecore.Marketing.Definitions.MarketingAssets.Repositories.config config Enable Enable Enable Enable Enable
Marketing Foundation \website\App_Config\Include Sitecore.Marketing.Definitions.MarketingAssets.Repositories.Lucene.Index.Master.config config Lucene Disable Enable Disable Enable Disable
Marketing Foundation \website\App_Config\Include Sitecore.Marketing.Definitions.MarketingAssets.Repositories.Lucene.Index.Web.config config Lucene Enable Disable Disable Disable Disable
Marketing Foundation \website\App_Config\Include Sitecore.Marketing.Definitions.MarketingAssets.Repositories.Lucene.IndexConfiguration.config config Lucene Enable Enable Disable Enable Disable
Marketing Foundation \website\App_Config\Include Sitecore.Marketing.Definitions.MarketingAssets.Repositories.Solr.Index.Master.config.disabled disabled Solr Disable Enable Disable Enable Disable
Marketing Foundation \website\App_Config\Include Sitecore.Marketing.Definitions.MarketingAssets.Repositories.Solr.Index.Web.config.disabled disabled Solr Enable Disable Disable Disable Disable
Marketing Foundation \website\App_Config\Include Sitecore.Marketing.Definitions.MarketingAssets.Repositories.Solr.IndexConfiguration.config.disabled disabled Solr Enable Enable Disable Enable Disable
Marketing Foundation \website\App_Config\Include Sitecore.Marketing.Definitions.MarketingAssets.RepositoriesCD.config.disabled config Enable Disable Disable Disable Disable
Marketing Foundation \website\App_Config\Include Sitecore.Marketing.Lucene.Index.Master.config config Lucene Disable Enable Disable Enable Disable
Marketing Foundation \website\App_Config\Include Sitecore.Marketing.Lucene.Index.Web.config config Lucene Enable Disable Disable Disable Disable
Marketing Foundation \website\App_Config\Include Sitecore.Marketing.Lucene.IndexConfiguration.config config Lucene Enable Enable Enable Enable Enable
Marketing Foundation \website\App_Config\Include Sitecore.Marketing.Search.config config Base Enable Enable Disable Enable Disable
Marketing Foundation \website\App_Config\Include Sitecore.Marketing.Solr.Index.Master.config.disabled disabled Solr Disable Enable Disable Enable Disable
Marketing Foundation \website\App_Config\Include Sitecore.Marketing.Solr.Index.Web.config.disabled disabled Solr Enable Disable Disable Disable Disable
Marketing Foundation \website\App_Config\Include Sitecore.Marketing.Solr.IndexConfiguration.config.disabled disabled Solr Enable Enable Disable Enable Disable
Marketing Foundation \website\App_Config\Include Sitecore.MarketingCD.config.disabled config Enable Disable Disable Disable Disable
Marketing Foundation \website\App_Config\Include Sitecore.MarketingProcessingRole.config.disabled disabled Disable Disable Enable Enable Disable
Marketing Foundation \website\App_Config\Include Sitecore.MarketingReportingRole.config.disabled disabled Disable Disable Disable Disable Enable
Platform \website\App_Config\Include Sitecore.Media.RequestProtection.config config Enable Enable Disable Enable Disable
Platform - MVC \website\App_Config\Include Sitecore.Mvc.config config Enable Enable Enable Enable Enable
Platform - MVC \website\App_Config\Include Sitecore.MvcAnalytics.config config Enable Enable Enable Enable Enable
Platform - MVC \website\App_Config\Include Sitecore.MvcExperienceEditor.config config Enable Enable Enable Enable Enable
Platform - MVC \website\App_Config\Include Sitecore.MvcSimulator.config config Enable Enable Enable Enable Enable
Path Analyzer \website\App_Config\Include Sitecore.PathAnalyzer.Client.config config Disable Enable Disable Enable Disable
Path Analyzer \website\App_Config\Include Sitecore.PathAnalyzer.config config Disable Enable Enable Enable Enable
Path Analyzer \website\App_Config\Include Sitecore.PathAnalyzer.Processing.config config Disable Disable Enable Enable Disable
Path Analyzer \website\App_Config\Include Sitecore.PathAnalyzer.RemoteClient.config.disabled disabled Disable Enable Disable Enable Disable
Path Analyzer \website\App_Config\Include Sitecore.PathAnalyzer.Services.config config Disable Enable Disable Enable Enable
Path Analyzer \website\App_Config\Include Sitecore.PathAnalyzer.Services.RemoteServer.config.disabled disabled Disable Disable Disable Disable Enable
Path Analyzer \website\App_Config\Include Sitecore.PathAnalyzer.StorageProviders.config config Disable Enable Enable Enable Enable
Platform \website\App_Config\Include Sitecore.PipelineProfiling.config.disabled disabled Enable Enable Enable Enable Enable
Platform \website\App_Config\Include Sitecore.Processing.config config Disable Enable Enable Enable Disable
Platform - Publishing \website\App_Config\Include Sitecore.Publishing.DedicatedInstance.config.example example NA NA NA NA NA
Platform - Publishing \website\App_Config\Include Sitecore.Publishing.EventProvider.Async.config.disabled disabled Disable Disable Disable Disable Disable
Platform - Publishing \website\App_Config\Include Sitecore.Publishing.Optimizations.config.example example NA NA NA NA NA
Platform - Publishing \website\App_Config\Include Sitecore.Publishing.Parallel.config.disabled disabled Disable Disable Disable Disable Disable
Platform - Publishing \website\App_Config\Include Sitecore.Publishing.Recovery.config.example example NA NA NA NA NA
Platform - Segments \website\App_Config\Include Sitecore.SegmentBuilder.config config Enable Enable Enable Enable Enable
Platform \website\App_Config\Include Sitecore.Services.Client.config config Enable Enable Enable Enable Enable
Marketing Foundation \website\App_Config\Include Sitecore.Shell.MarketingAutomation.config config Disable Enable Disable Enable Disable
SPEAK \website\App_Config\Include Sitecore.Speak.AntiCsrf.SheerUI.config config Disable Enable Disable Enable Disable
SPEAK \website\App_Config\Include Sitecore.Speak.Applications.config config Disable Enable Enable Enable Enable
SPEAK \website\App_Config\Include Sitecore.Speak.ContentSearch.Lucene.config config Lucene Disable Enable Disable Enable Disable
SPEAK \website\App_Config\Include Sitecore.Speak.ContentSearch.Solr.config.example config Solr Disable Enable Disable Enable Disable
SPEAK \website\App_Config\Include Sitecore.Speak.Components.config config Disable Enable Disable Enable Disable
SPEAK \website\App_Config\Include Sitecore.Speak.config config Disable Enable Disable Enable Disable
SPEAK \website\App_Config\Include Sitecore.Speak.ItemWebApi.config config Disable Enable Disable Enable Disable
SPEAK \website\App_Config\Include Sitecore.Speak.LaunchPad.config config Disable Enable Disable Enable Disable
SPEAK \website\App_Config\Include Sitecore.Speak.Mvc.config config Disable Enable Disable Enable Disable
Platform \website\App_Config\Include Sitecore.WebDAV.config config Disable Enable Disable Enable Disable
Marketing Foundation \website\App_Config\Include Sitecore.Xdb.config config Enable Enable Enable Enable Enable
Marketing Foundation \website\App_Config\Include Sitecore.Xdb.Remote.Client.config.disabled disabled Disable Enable Disable Enable Disable
Marketing Foundation \website\App_Config\Include Sitecore.Xdb.Remote.Client.MarketingAssets.config.disabled disabled Disable Enable Disable Enable Disable
Marketing Foundation \website\App_Config\Include Sitecore.Xdb.Remote.Server.config.disabled disabled Disable Disable Disable Disable Enable
Marketing Foundation \website\App_Config\Include Sitecore.Xdb.Remote.Server.MarketingAssets.config.disabled disabled Disable Disable Disable Disable Enable
Platform \website\App_Config\Include SitecoreSettings.config.example example NA NA NA NA NA
Platform \website\App_Config\Include SiteDefinition.config.example example NA NA NA NA NA
Platform \website\App_Config\Include UseServerSideRedirect.config config Enable Enable Enable Enable Enable
Platform \website\App_Config\Include WebDeploy.config.example example NA NA NA NA NA
Platform \website\App_Config\Include XslExtension.config.example example NA NA NA NA NA
Detection Services \website\App_Config\Include\CES Sitecore.CES.config config Enable Enable Enable Enable Enable
Detection Services \website\App_Config\Include\CES Sitecore.CES.DeviceDetection.CheckInitialization.config.disabled disabled Disable Disable Enable Enable Disable
Detection Services \website\App_Config\Include\CES Sitecore.CES.DeviceDetection.config config Enable Enable Enable Enable Enable
Detection Services \website\App_Config\Include\CES Sitecore.CES.GeoIp.config config Enable Enable Enable Enable Enable
Detection Services \website\App_Config\Include\CES Sitecore.CES.GeoIp.LegacyLocation.config config Enable Enable Enable Enable Enable
Marketing Foundation \website\App_Config\Include\Channel Sitecore.Analytics.Channel.config config Enable Enable Enable Enable Enable
Content Testing \website\App_Config\Include\ContentTesting Sitecore.ContentTesting.ApplicationDependencies.config config Disable Enable Disable Enable Disable
Content Testing \website\App_Config\Include\ContentTesting Sitecore.ContentTesting.Client.RulePerformance.config.disabled disabled Disable Enable Disable Enable Disable
Content Testing \website\App_Config\Include\ContentTesting Sitecore.ContentTesting.config config Enable Enable Enable Enable Enable
Content Testing \website\App_Config\Include\ContentTesting Sitecore.ContentTesting.Intelligence.config config Enable Enable Enable Enable Enable
Content Testing \website\App_Config\Include\ContentTesting Sitecore.ContentTesting.Lucene.IndexConfiguration.config config Lucene Disable Enable Enable Enable Disable
Content Testing \website\App_Config\Include\ContentTesting Sitecore.ContentTesting.Mvc.config config Enable Enable Enable Enable Enable
Content Testing \website\App_Config\Include\ContentTesting Sitecore.ContentTesting.PreemptiveScreenshot.config.disabled disabled Disable Enable Disable Enable Disable
Content Testing \website\App_Config\Include\ContentTesting Sitecore.ContentTesting.Processing.Aggregation.config config Disable Disable Enable Enable Disable
Content Testing \website\App_Config\Include\ContentTesting Sitecore.ContentTesting.Solr.IndexConfiguration.config.disabled disabled Solr Disable Enable Enable Enable Disable
Experience Analytics \website\App_Config\Include\ExperienceAnalytics Sitecore.ExperienceAnalytics.Aggregation.config config Disable Disable Enable Enable Disable
Experience Analytics \website\App_Config\Include\ExperienceAnalytics Sitecore.ExperienceAnalytics.Client.config config Disable Enable Disable Enable Disable
Experience Analytics \website\App_Config\Include\ExperienceAnalytics Sitecore.ExperienceAnalytics.ReAggregation.config.disabled disabled Disable Disable Enable Enable Enable
Experience Analytics \website\App_Config\Include\ExperienceAnalytics Sitecore.ExperienceAnalytics.ReAggregation.Scheduling.config.disabled disabled Disable Disable Disable Disable Enable
Experience Analytics \website\App_Config\Include\ExperienceAnalytics Sitecore.ExperienceAnalytics.Reduce.config config Disable Disable Disable Disable Enable
Experience Analytics \website\App_Config\Include\ExperienceAnalytics Sitecore.ExperienceAnalytics.StorageProviders.config config Disable Disable Enable Enable Enable
Experience Analytics \website\App_Config\Include\ExperienceAnalytics Sitecore.ExperienceAnalytics.WebAPI.config config Disable Enable Disable Enable Disable
Experience Profile \website\App_Config\Include\ExperienceProfile Sitecore.ExperienceProfile.Client.config config Disable Enable Disable Enable Disable
Experience Profile \website\App_Config\Include\ExperienceProfile Sitecore.ExperienceProfile.config config Disable Enable Disable Enable Enable
Experience Profile \website\App_Config\Include\ExperienceProfile Sitecore.ExperienceProfile.Reporting.config config Disable Enable Disable Enable Enable
FXM \website\App_Config\Include\FXM Sitecore.FXM.Bundle.config config Enable Enable Enable Enable Enable
FXM \website\App_Config\Include\FXM Sitecore.FXM.config config Enable Enable Enable Enable Enable
FXM \website\App_Config\Include\FXM Sitecore.FXM.Lucene.DomainsSearch.DefaultIndexConfiguration.config config Lucene Disable Enable Disable Enable Disable
FXM \website\App_Config\Include\FXM Sitecore.FXM.Lucene.DomainsSearch.Index.Master.config config Lucene Disable Enable Disable Enable Disable
FXM \website\App_Config\Include\FXM Sitecore.FXM.Lucene.DomainsSearch.Index.Web.config config Lucene Enable Disable Disable Disable Disable
FXM \website\App_Config\Include\FXM Sitecore.FXM.Solr.DomainsSearch.DefaultIndexConfiguration.config.disabled disabled Solr Disable Enable Disable Enable Disable
FXM \website\App_Config\Include\FXM Sitecore.FXM.Solr.DomainsSearch.Index.Master.config.disabled disabled Solr Disable Enable Disable Enable Disable
FXM \website\App_Config\Include\FXM Sitecore.FXM.Solr.DomainsSearch.Index.Web.config.disabled disabled Solr Enable Disable Disable Disable Disable
FXM \website\App_Config\Include\FXM Sitecore.FXM.Speak.config config Disable Enable Disable Enable Disable
Platform - Language Fallback \website\App_Config\Include\ Sitecore.LanguageFallback.config config Enable Enable Enable Enable Enable
List Management \website\App_Config\Include\ListManagement Sitecore.ListManagement.Client.config config Disable Enable Disable Enable Disable
List Management \website\App_Config\Include\ListManagement Sitecore.ListManagement.config config Disable Enable Disable Enable Disable
List Management \website\App_Config\Include\ListManagement Sitecore.ListManagement.Lucene.Index.List.config config Lucene Disable Enable Disable Enable Disable
List Management \website\App_Config\Include\ListManagement Sitecore.ListManagement.Lucene.IndexConfiguration.config config Lucene Disable Enable Disable Enable Disable
List Management \website\App_Config\Include\ListManagement Sitecore.ListManagement.Services.config config Disable Enable Disable Enable Disable
List Management \website\App_Config\Include\ListManagement Sitecore.ListManagement.Solr.Index.List.config.disabled disabled Solr Disable Enable Disable Enable Disable
List Management \website\App_Config\Include\ListManagement Sitecore.ListManagement.Solr.IndexConfiguration.config.disabled disabled Solr Disable Enable Disable Enable Disable
Campaign Creation Tool \website\App_Config\Include\Marketing Sitecore.Marketing.Campaigns.Client.config config Enable Enable Enable Enable Enable
Campaign Creation Tool \website\App_Config\Include\Marketing Sitecore.Marketing.Campaigns.Services.config config Enable Enable Enable Enable Enable
Social \website\App_Config\Include\Social Sitecore.Social.config config Enable Enable Disable Enable Disable
Social \website\App_Config\Include\Social Sitecore.Social.ExperienceProfile.config config Disable Enable Disable Enable Disable
Social \website\App_Config\Include\Social Sitecore.Social.Facebook.config config Enable Enable Disable Enable Disable
Social \website\App_Config\Include\Social Sitecore.Social.GooglePlus.config config Enable Enable Disable Enable Disable
Social \website\App_Config\Include\Social Sitecore.Social.Klout.config.disabled disabled Disable Disable Disable Disable Disable
Social \website\App_Config\Include\Social Sitecore.Social.LinkedIn.config config Enable Enable Disable Enable Disable
Social \website\App_Config\Include\Social Sitecore.Social.Lucene.Index.Master.config config Lucene Disable Enable Disable Enable Disable
Social \website\App_Config\Include\Social Sitecore.Social.Lucene.Index.Web.config config Lucene Enable Disable Disable Disable Disable
Social \website\App_Config\Include\Social Sitecore.Social.Lucene.IndexConfiguration.config config Lucene Enable Enable Disable Enable Disable
Social \website\App_Config\Include\Social Sitecore.Social.ProfileMapping.Facebook.config config Enable Enable Disable Enable Disable
Social \website\App_Config\Include\Social Sitecore.Social.ProfileMapping.GooglePlus.config config Enable Enable Disable Enable Disable
Social \website\App_Config\Include\Social Sitecore.Social.ProfileMapping.LinkedIn.config config Enable Enable Disable Enable Disable
Social \website\App_Config\Include\Social Sitecore.Social.ProfileMapping.Twitter.config config Enable Enable Disable Enable Disable
Social \website\App_Config\Include\Social Sitecore.Social.ScalabilitySettings.config.disabled disabled Enable Enable Disable Enable Disable
Social \website\App_Config\Include\Social Sitecore.Social.SocialMarketer.config config Enable Enable Disable Enable Disable
Social \website\App_Config\Include\Social Sitecore.Social.Solr.Index.Master.config.disabled disabled Solr Disable Enable Disable Enable Disable
Social \website\App_Config\Include\Social Sitecore.Social.Solr.Index.Web.config.disabled disabled Solr Enable Disable Disable Disable Disable
Social \website\App_Config\Include\Social Sitecore.Social.Solr.IndexConfiguration.config.disabled disabled Solr Enable Enable Disable Enable Disable
Social \website\App_Config\Include\Social Sitecore.Social.Twitter.config config Enable Enable Disable Enable Disable
xDB Cloud \website\App_Config\Include\XdbCloud Sitecore.Cloud.Xdb.config.disabled disabled Disable Disable Disable Disable Disable
xDB Cloud \website\App_Config\Include\XdbCloud Sitecore.ContentSearch.Cloud.DefaultIndexConfiguration.config.disabled disabled Disable Disable Disable Disable Disable
xDB Cloud \website\App_Config\Include\XdbCloud Sitecore.ContentSearch.Cloud.Index.Analytics.config.disabled disabled Disable Disable Disable Disable Disable
Platform \website\App_Config\Include\Z.SwitchMasterToWeb important.txt txt NA NA NA NA NA
Platform \website\App_Config\Include\Z.SwitchMasterToWeb SwitchMasterToWeb.config.example example NA NA NA NA NA
Platform \website\App_Config\Include\zzz\ DataFolder.config config Enable Enable Enable Enable Enable
Platform \website\App_Config\Include\zzz\ UseServerSideRedirect.config config Enable Enable Enable Enable Enable
Platform \website\App_Config\Prefetch Common.config config Enable Enable Enable Enable Enable
Platform \website\App_Config\Prefetch Core.config config Enable Enable Enable Enable Enable
Platform \website\App_Config\Prefetch Master.config config Enable Enable Enable Enable Enable
Platform \website\App_Config\Prefetch Webdb.config config Enable Enable Enable Enable Enable
Platform \website\App_Config\Security Domains.config config Enable Enable Enable Enable Enable
Platform \website\App_Config\Security GlobalRoles.config config Enable Enable Enable Enable Enable
Marketing Foundation \website\sitecore\shell\Applications\MarketingAutomation Configuration.config config Enable Enable Enable Enable Enable
Exec Insight Dashboard \website\sitecore\shell\Applications\Reports\Dashboard CampaignCategoryDefaultSettings.config config Disable Disable Disable Disable Disable
Exec Insight Dashboard \website\sitecore\shell\Applications\Reports\Dashboard Configuration.config config Disable Disable Disable Disable Disable
Exec Insight Dashboard \website\sitecore\shell\Applications\Reports\Dashboard DefaultSettings.config config Disable Disable Disable Disable Disable
Exec Insight Dashboard \website\sitecore\shell\Applications\Reports\Dashboard SingleCampaignDefaultSettings.config config Disable Disable Disable Disable Disable
Exec Insight Dashboard \website\sitecore\shell\Applications\Reports\Dashboard SingleTrafficTypeDefaultSettings.config config Disable Disable Disable Disable Disable
<#
.SYNOPSIS
The following script prompts the user for a Sitecore server role, then applies the appropriate configurations as specified by the spreadsheet.
.NOTES
Michael West
2016-06-17
#>
$VerbosePreference = "Silentlycontinue"
$configOptions = Import-Csv -Path C:\temp\Config_Enable-Disable_Sitecore_8.1_upd3.csv
$role = Read-Host -Prompt "Which server role would you like to use? (i.e. CD, CM, CMP, PRC, RPT)"
$apppath = "C:\temp\"
foreach($option in $configOptions) {
$configPath = Join-Path -Path $apppath -ChildPath $option.Filepath
switch($option.$role) {
"Enable" {
Write-Host "Enabling $($option.Filename)"
$oldConfigPath = Join-Path -Path $configPath -ChildPath ($option.Filename + "*")
$newConfigPath = Join-Path -Path $configPath -ChildPath $option.Filename
}
"Disable" {
Write-Host "Disabling $($option.Filename)"
$oldConfigPath = Join-Path -Path $configPath -ChildPath ($option.Filename + "*")
$newConfigPath = Join-Path -Path $configPath -ChildPath ($option.Filename + ".disabled")
}
default {
continue
}
}
if(-not (Test-Path -Path $oldConfigPath)) {
Write-Verbose "Skipping $($oldConfigPath) because the path does not exist."
continue
}
Move-Item -Path $oldConfigPath -Destination $newConfigPath
}

AdamNaj commented Jun 17, 2016 edited by michaellwest

How about not having to enter your role as text?

$roles = [ordered]@{"Content Delivery"="CD";"Content Management"="CM";"Content Management + Processing"="CMP";"Processing"="PRC"; "Reporting"="RPT"};
$role = "CM"
$searchProviders = [ordered]@{"Lucene"="Lucene";"Solr"="Solr"};
$searchProvider = "Lucene"

$result = Read-Variable -Parameters `
    @{ Name = "role"; Title="Server Type"; Options=$roles; Editor="radio" }, `
    @{ Name = "searchProvider"; Title="search Provider"; Options=$searchProviders; Editor="radio" } `
    -Description "This script helps you enable and disable configs that are relevant to your server role and search providers used" `
    -Title "Enable relevant configs" -Width 650 -Height 660 -OkButtonName "Proceed" -CancelButtonName "Abort" -ShowHints


if($result -ne "ok")
{
    Exit
}

Instead of line 13...

Prepared for enabling/disabling based on search provider value.
I think it would be an awesome script to add to SPE OR a separate Marketplace module?

Owner

michaellwest commented Jun 17, 2016

This was initially designed to work outside of Sitecore; something perhaps the Ops team would use, or a developer on his/her local box. I can see how a dialog from within SPE would be valuable.

Michael,

i'm seeing times when the script doesn't work. I'm thinking it has something to do with the filename within the CSV. some end in .disable others in .example. It looks like your script is making an assumption that all files end in .config. As a result, some configs are being missed. but that doesn't always apply and i'm seeing other items not being set. Let me know if i'm missing something. I'm using the "CMP" role. Here are a couple of examples of files that are not being enabled/disabled:

Should be enabled:
Sitecore.CES.DeviceDetection.CheckInitialization.config.disabled
Sitecore.MarketingProcessingRole.config.disabled
Sitecore.Analytics.Tracking.Database.ScaledCM.config.disabled

Should be disabled:
Sitecore.Analytics.ExcludeRobots.config
Sitecore.Analytics.Tracking.Aggregation.config

peplau commented Sep 23, 2016

Hey Michael, I have changed your script a bit so it is now able to show the differences between the CSV and a Sitecore installation.
Check it out: https://gist.github.com/peplau/6d1588821675c2dda15c18fabbd94eb8

Hey Michael,

What powershell version is this? $option.Filename.disabled is not working for me. When I output that line, it prints the path without the filename so it's no renaming any of them :(

josedbaez commented Nov 2, 2016 edited

I had to change line 29 to:
$newConfigPath = [io.path]::combine($configPath, $option.Filename + '.disabled')
or
$newConfigPath = Join-Path -Path $configPath -ChildPath ($option.Filename + ".disabled")

Thank you Michael.

Owner

michaellwest commented Nov 21, 2016

Thank you @josedbaez, I made the change as you recommended. Your way is the proper way to do it.

Owner

michaellwest commented Nov 21, 2016

@fcb-chrisbrown I think the issue turned out to be what @josedbaez corrected.

Hey Michael,
It is a great script, it helps a lot!
However, I'm seeing some problems when the files are named as .EXAMPLE and need to be ENABLED they are not. And I noticed that in order to get those proper changed I've to change in the CSV file from .EXAMPLE to .CONFIG

For example, if I use the following line, the ScalabilitySettings keeps within .EXAMPLE
Platform,\website\App_Config\Include,ScalabilitySettings.config.example,example,,Enable,Enable,Enable,Enable,Enable

But, if I change to .CONFIG then it renames
Platform,\website\App_Config\Include,ScalabilitySettings.config,config,,Enable,Enable,Enable,Enable,Enable

Do you have any tricks other than manually change it to get this working?

Thanks,

Vinicius

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment