Building an MSI Database
If you do not create MSI files during the capture process, you can still create these files after building an application. An MSI database is useful for delivering captured applications through traditional desktop management systems to remote locations and automatically creating shortcuts and file type associations. Basic Active Directory group policies provide ways to distribute and start MSI packages.
ThinApp creates an MSI database that contains captured executable files, installer logic, and the thinreg.exe utility.
Customizing MSI Files with Package.ini Parameters
You can customize the behavior of MSI files by modifying Package.ini parameters and rebuilding the application package.
The following parameters can affect MSI configuration:
The MSIInstallDirectory parameter sets the installation directory for the package.
For example, include MSIInstallDirectory=C:\Program Files\ in the Package.ini file.
The MSIDefaultInstallAllUsers parameter sets whether to install the package for all or individual users. ThinApp installs the package in the %AppData% user directory.
For example, include MSIDefaultInstallAllUsers=0 in the Package.ini file.
For more information about this parameter, see Specifying a Database Installation for Individual Users and Machines.
The MSIFileName parameter names the package.
For example, include MSIFilename=Firefox30.msi in the Package.ini file.
The MSIRequireElevatedPrivileges parameter indicates whether an installer needs elevated privileges for deployment on Microsoft Vista. Installations for individual users do not usually need elevated privileges but per-machine installations require such privileges.
For example, include MSIRequireElevatedPrivileges=1 in the Package.ini file.
The MSIProductCode parameter makes it easier to install a new version of the application. An MSI database contains a product code and an upgrade code. When you update a package, keep the original value of the MSIUpgradeCode parameter.
If the parameter value of the new version is the same as the value of the old version, the installation prompts you to remove the old version. If the values for the parameter are different, the installation un installs the old version and installs the new version.
VMware recommends that you avoid specifying an MSIProductCode value and allow ThinApp to generate a different product code for each build.
Regardless of the parameter values specified at build time, you can override the settings at deployment time. See Force MSI Deployments for Each User or Each Machine.
Modify the Package.ini File to Create MSI Files
For more information about MSI parameters, see Customizing MSI Files with Package.ini Parameters.
Before you can modify MSI parameters, you must add an entry for the MSIFilename parameter to generate MSI files.
Modify the MSI parameters
1
In the Package.ini file, type the MSI filename.
MSIFilename=<filename>.msi
For example, the filename for Firefox might be Mozilla Firefox 2.0.0.3.msi.
2
3
Double-click the build.bat file in the captured application folder to rebuild the application package.
Specifying a Database Installation for Individual Users and Machines
You can modify the installation of the MSI database for users and machines.
ThinApp installs the MSI database across all machines. You can change the default installation with the following parameter values:
To create a database installation for individual users, use a value of 0 for the MSIDefaultInstallAllUsers parameter in the Package.ini file. This value creates msiexec parameters for each user.
To allow administrators to create a database installation for all users on a machine, or to allow an individual user without administrator rights to create an installation only for that user, use a value of 2 for the MSIDefaultInstallAllUsers parameter. Administrators belong to the Administrators Active Directory group.
For more information about the MSIDefaultInstallAllUsers parameter, refer ThinApp Package.ini Parameters Reference Guide.
Force MSI Deployments for Each User or Each Machine
Regardless of the parameter values specified at build time, you can override MSI settings at deployment time.
For example, if you created the database with a value of 1 for the MSIDefaultInstallAllUsers parameter, you can still force individual user deployments for Firefox 3.0 with the msiexec /i Firefox30.msi ALLUSERS="" command.
If you use the ALLUSERS="" argument for the msiexec command, ThinApp extracts the captured executable files to the %AppData% user directory.
Deploying 64 bit MSI
Set Package.ini parameter MSIIs64Bit to install 64 bit MSI to ProgramFiles instead of ProgramFiles(x86) on 64 bit system.
Example
MSIIs64Bit=1
Force MSI Deployments for Individual Users or for All Users on a Machine
(Optional) From the command line, type the msiexec /i <database>.msi ALLUSERS="" command to force deployments for individual users.
(Optional) From the command line, type the msiexec /i <database>.msi ALLUSERS=1 command to force deployments for all users on a machine.
Override the MSI Installation Directory
You can use the msiexec command to override the default MSI installation directory.
When ThinApp performs an individual machine MSI deployment, the default installation directory is the localized equivalent of %ProgramFilesDir%\<inventory_name> (VMware ThinApp). If you install a Firefox package for each machine, the package resides in %ProgramFilesDir%\Mozilla Firefox (VMware ThinApp).
When ThinApp performs an MSI deployment for individual users, the default installation directory is %AppData%\<inventory_name> (VMware ThinApp).
In both cases, you can override the installation directory by passing an INSTALLDIR property to the msiexec command.
Override the MSI Installation Directory
From the command line, type the msiexec /i <database>.msi INSTALLDIR=C:\<my_directory>\<my_package> command.
Deploying MSI Files on Microsoft Vista
When you deploy MSI files on Vista, you must indicate whether an installer needs elevated privileges. Typical individual user installations do not require elevated privileges but individual machine installations require such privileges.
ThinApp provides the MSIRequireElevatedPrivileges parameter in the Package.ini file that specifies the need for elevated privileges when the value is set to 1. Specifying a value of 1 for this parameter or forcing an individual user installation from the command line can generate UAC prompts. Specifying a value of 0 for this parameter prevents UAC prompts but the deployment fails for machine-wide installations.