All of the Atomia applications are configurable trough configuration files within application. Those configuration files are generated trough Microsoft's web.config transformation tools. Essentially, each configuration files within Atomia is generated of 3 different files:

  • Original configuration file

  • Atomia ini file
  • Transformation file(s)
Here is short description of each:

Original configuration file

This is default configuration file that represents base of future configuration file. This is basically starting position. Relative to actual configuration file, this files location is folder Original Files which is in same folder as actual configuration file. This file is named same as actual configuration file. Example:

Actual config file: C:\Program Files (x86)\Atomia\HostingControlPanel\Web.config

Original file: C:\Program Files (x86)\Atomia\HostingControlPanel\Original Files\Web.config


Atomia ini file
This is file that stores environment variables specific for the environment where Atomia is running. For example, here are stored certificate thumbprints, domain names of applications, path to log files, SQL and email server connection parameters, etc. Location of this files is configurable. You can check it in C:\Program Files (x86)\Atomia\Common\atomia.ini.location. Usually it is C:\Program Files (x86)\Atomia\Common\unattended.ini.

Transformation file
This files contains set of rules for transforming Original configuration file to suite customer's specific configuration. For each Original configuration file, there can be multiple transformation files. Relative to actual configuration file, this files location is folder Transformation Files which is in same folder as actual configuration file. This file's name is derived from actual configuration file's name by inserting string by desire before file extension. Example:

Actual config file: C:\Program Files (x86)\Atomia\HostingControlPanel\Web.config

Original file: C:\Program Files (x86)\Atomia\HostingControlPanel\Transformation Files\Web.MyTransormation.config


Web.config transformation tool takes Original configuration file, replaces placeholders with actual environment values defined in Atomia ini file and then applies transformations defined in Transformation file(s). Resulting product of this process is acctual configuration file used by Atomia application.

All custom changes in Atomia configuration have to be done trough Transformation files. This is essential since all changes done directly in configuration file will be rewritten during next transformation execution (it happens always during system updates and can be initiated manually as well). Here is an example of actual reconfiguration process:

  1. Open existing transformation file for desired configuration file or create new one taking care of naming conventions. Example: C:\Program Files (x86)\Atomia\HostingControlPanel\Transformation Files\Web.MyTransormation.config
  2. Put desired transformation in the file and save it. Example:

     

    <?xml version="1.0" encoding="utf-8"?>
    <configuration  xmlns:xdt="http://schemas.microsoft.com/XML-Document-Transform" xmlns:is="http://schemas.atomia.com/2009/06/configuration/identity" xmlns:hy="urn:nhibernate-configuration-2.2">
        <appConfig xmlns="Atomia.Web.Base.Configs">
            <pluginSettingsList>
                <pluginSettingsPlugin pluginName="Website" xdt:Locator="Match(pluginName)">
    				<!-- Following line finds pluginSetting tag with name UsageStatsEnabled and replaces it with <pluginSetting name="UsageStatsEnabled" value="false" />, whatever attributs tag had before. -->
    				<pluginSetting name="UsageStatsEnabled" value="false" xdt:Transform="Replace" xdt:Locator="Match(name)" />
    				<!-- Following line finds pluginSetting tag with name categoryGroups and replaces it with <pluginSetting name="categoryGroups" value="{ 'Popular': [ 'drupal', 'wordpress', 'joomla', 'concrete', 'vanilla', 'opencart' ] }" />, whatever attributs tag had before. -->
    				<pluginSetting name="categoryGroups" value="{ 'Popular': [ 'drupal', 'wordpress', 'joomla', 'concrete', 'vanilla', 'opencart' ] }" xdt:Locator="Match(name)" xdt:Transform="Replace" />
                </pluginSettingsPlugin>
            </pluginSettingsList>
        </appConfig>
    </configuration>

     

  3. Run transformation tool link which is located in Application's root folder: C:\Program Files (x86)\Atomia\HostingControlPanel\Recreate config files
You reconfiguration is finished.

Rules for creating transformation files can be found on this link: Transform Attribute Syntax