-
Notifications
You must be signed in to change notification settings - Fork 27
Description
I am frustrated that I cannot configure the container project to the same level as my on-premise project. There is far more flexibility is prefix naming conventions.
REQUEST
- Add parameter to ComposeInit.ps1 for $SqlDatabasePrefix
- Add parameter to ComposeInit.ps1 for $SqlCommerceDatabasePrefix
- Add parameter to ComposeInit.ps1 for $SolrCorePrefix
- Add parameter to ComposeInit.ps1 for $SolrCommerceCorePrefix
There already exists, in the .env file, options to customize these values. However, they cannot be provided through the parameters sent to the ComposeInit.ps1 script. I had to write a PowerShell script to overwrite these values before running the ComposeInit.ps1. Here is the script I am using:
(Get-Content "C:\Sitecore\xc1-cxa\.env") -replace "SQL_DATABASE_PREFIX=Sitecore","SQL_DATABASE_PREFIX=rrx" | Out-File "C:\Sitecore\xc1-cxa\.env"
(Get-Content "C:\Sitecore\xc1-cxa\.env") -replace "SOLR_CORE_PREFIX_NAME=sitecore","SOLR_CORE_PREFIX_NAME=rrx" | Out-File "C:\Sitecore\xc1-cxa\.env"
(Get-Content "C:\Sitecore\xc1-cxa\.env") -replace "SOLR_COMMERCE_PREFIX_NAME=commerce","SOLR_COMMERCE_PREFIX_NAME=rrx" | Out-File "C:\Sitecore\xc1-cxa\.env"
The commerce database prefix is the big problem. I searched and replaced all instances of SitecoreCommerce_ with xxx.SitecoreCommerce_ to force the 3 commerce databases to have a prefix. It did not work. No matter what I do to the configuration files it always attaches with the standard naming. I believe there is something in the docker image which is hard coded. Notice the screenshot, no prefixes.