User guide

22
9. Select the configuration variable replacement mode from the Variable Replacement Mode dropdown.
Variable Replacement Mode
The Variable Replacement Mode determines when the configuration variable tokens will be replaced
with their values during a deployment. The following options are available: Never, Before Installation,
After Installation and, Before and After Installation.
Only in Command
The variables will only be replaced in the installation command if any
Before Installation
The variables will be replaced in the installation command and before executing the
installation command
After Installation
The variables will be replaced in the installation command and after executing the
installation command
Before and After Installation
The variables will be replaced in the installation command, before and after executing
the installation command
MSI deployment agent example
Using an MSI Deployer, the mode has to be After Installation. The reason is that only after executing
the MSI that we have the config files extracted and available to the Deployer to replace.
XCopy deployment agent example
Using the XCopy deployment agent, the mode can be either Before Installation or After Installation.
The reason is when the variables are replaced before execution of the xcopy command, the files being
copied will already contain the right values instead of the token. When they are replaced after, the final
files get scanned and modified with correct values.
Note that when using After Installation, only the files contained in the Installation Path folder (supplied
by a mandatory configuration variable) will be replaced.
File Extension Filter
When the selection is Before Installation, After Installation or Before and After installation, the File
Extension Filter needs to be provided. This tells the deployment agent which files needs to be scanned
when replacing the variables. It uses a matching pattern to find the files. If multiple patterns are needed,
separate them with a semi-colon (;).
Example of Pattern
*.*
*.config
MyApp.MyModule.exe.config
*.config;*.xml