If you automate your application installs then you will probably have used an Install Wrapper.
When installing something in an unattended (i.e. automated) way, often there is a simple, single command line that you can use. For example the following single command line will install 7-Zip with a basic msiexec User Interface (UI) whilst ensuring the install doesn’t trigger a reboot,
msiexec /i "C:\Path\To\7z920-x64.msi" ALLUSERS=1 /norestart /qb-
This command line is generally inserted into you your deployment tool of choice to deliver the software to your Windows endpoint (we use Altiris DS6.9 and Altiris CMS7).
But what if your unattended installation has a pre-requisite? Or what if after the installation you need to perform a task or install a post-requisite?
This is the point when most software packagers start writing a batch file. To illustrate, below is an example of a batch file which will install iTunes with its pre-requisites:
REM a batch file msiexec.exe /i "C:\Path\To\AppleApplicationSupport.msi" ALLUSERS=1 /norestart /qb- msiexec.exe /i "C:\Path\To\AppleMobileDeviceSupport64.msi" ALLUSERS=1 /norestart /qb- msiexec.exe /i "C:\Path\To\iTunes64.msi" TRANSFORMS="C:\Path\To\iTunes64_ITS.mst" ALLUSERS=1 /norestart /qb- REM end of batch file
Now imagine this batch file is called ‘Install_iTunes.cmd’ and that this is the command line that you used in your favourite deployment tool:
"C:\Path\To\Install_iTunes.cmd"
The batch file you have now created is an Install Wrapper.
An Install Wrapper can be created using any scripting or programming language and the objective generally is to ensure the application can be fully (and robustly) installed in an unattended manner on the target machine. (Please note that I do not use the word ‘silent’ in this regard; many software packagers use the words silent and unattended interchangeably in reference to application installations. This can be confusing as some vendor silent switch implementations only make the installation fully automated, i.e. unattended, and do not also actually make the install silent/invisible)
Install wrappers are usually required for one of the following reasons (although there are as many reasons as imagined scenarios):
Pre / Post-requisites
Pre / Post scripting, e.g: delete a file / shortcut, create a registry key
Pre-install condition checking, e.g: correct OS, correct computer name (or part of name)
Check the version of an installed pre-requisite, e.g: version of MS Office
Check if a user is logged on
Check if a program is in use by the user, e.g: in the event of an upgrade
Software install wrappers are often written to perform unattended software installs which require more logic or requisites than a simple silent switch.
If you use a endpoint management product it will often natively provide various UI features to help you ‘wrap’ your software installs without requiring scripting expertise. For example with Altiris 7.5 we have conditions based on filters and compliance decided by detection rules. Endpoint management products however, can’t always handle the logic you need incorporated into your installation. In such scenarios you have your deployment tool of choice execute a wrapper script to manage the install instead.
The down side to Install Wrappers is that the more complex the application requirements and install phases become, the more skilled the programmer / scripter needs to be. And this can become a problem; we found that when we needed to hire packaging contractors we could only hire those with accomplished scripting skills. Consequently the hiring process became much more difficult.
To mitigate this, I decided to create a simple-to-use VBScript based wrapper which would be driven entirely by an ini file. The aim was to remove the scripting aspect from the packaging team’s duties so that they would only need to edit the ini file (according to a reference I’ve written) to manage any software installation. I called the resulting VBScript the ‘General Installer’, or ‘GInstaller’ (jee-installer) for short. I will at some point document and release this to the community so that maybe more packagers can benefit from this as we have.
So to summarise, an Install Wrapper is the program or script that you use to execute your installation including any additional programmed logic, pre or post-requisites, and including any additional scripting tasks such as file or registry operations.
I hope that you found this useful!
(Note: originally published on Symantec Connect. Symantec was bought by Broadcom and this post was re-published in Broadcom Communities)