AutoIt3 Unattended Software Deployment

Summary

Deployment.exe can install Au3 scripts in a easy sequence that is executed at Cmdlines.txt (T-12) and RunOnce (T-00).
Note: T-12 or T-00 is Time minus ?? minutes left until end of Windows Setup.

The benefits of running Deployment.exe are as follows:

Setup

When the Deployment.exe is run without switches, it will check that it is within the $OEM$ folder, then ask to continue to check if required files or folders do not exist, then it will create them for you. If any of the Au3 scripts created are not needed, then just delete them as their existance will be logged as simply missing.

Switches

The /Execute switch will set Deployment.exe into installation mode which will happen immediately.
Using /NoOnTop in the commandline also will set the background with the OnTop status as disabled.
When itinially setup without switches, a Cmdlines.txt file (only if not exist) will be created with the switch added that you select as a method to use. /? can be used on Deployment.exe for help with switches tio use.

Settings

An optional Settings.ini file is created in the same directory as Deployment.exe. This allows a custom change of font colours and change colour of the progressbar. The format of the values need to be in a hex format as shown in the file. If the file is not present during Installation, then the default colours will be used.

Background

The default background picture used is the XP blue billboard but an option is available for those who want to use another. The script will search in it's own directory for Background.bmp, Background.jpg or Background.gif. If either of these files is found first, then the found background picture will be used rather then the default background picture.

Installations

If you choose to install your software at Cmdlines.txt. Then you just need to add your Au3 files and installer into the T-12_Software folder. At T-12, the _Prepare.au3 script will execute before the software installs take place, and the cleanup script will cleanup afterwards. Some software wil not install from Cmdlines.txt, so the Deployment.exe will executed again from the HKLM\....\RunOnce key so any Au3 scripts that are found in the T-00_Software folder will be executed to do further installations.

If the T-12_Software folder or the T-00_Software folder is found in the root of another available drive, then the found folder will be used as the folder to install from. This allows the software to be stored and updated on another partition or drive rather then on the CD/DVD media. Storing software on a HardDrive would mean that the CD/DVD media does not need updating just because of software updates.

The _Prepare.au3, _Cleanup.au3 and _Startup.au3 scripts will be used for mostly global system changes, as the software installation scripts can remove shortcuts, add / remove files , add / remove registry entries, and many other functions that Au3 scripts can do. Any software tasks should be retained within the same install script that installs the software itself.

Visual

The structure of your project will display as such:

CDRoot
- $OEM$ folder
- - T-12_Software folder
- - T-00_Software folder
- - Deployment.exe
- - _Cleanup.au3
- - _Prepare.au3
- - _Startup.au3

Cmdlines.txt will contain the following when installing immediately

[COMMANDS]
"Deployment.exe /Execute"

Disable the OnTop status permanently for the background (needed if automation scripts require active windows)

[COMMANDS]
"Deployment.exe /Execute /NoOnTop"

You can run a safe test to view the background for a few seconds. Good for checking that your background works ok.

“Deployment,exe /Test”

This is a timeline of operation showing sequence of events

T-12

Open Deployment.log in @WindowsDir
Execute _Prepare.au3
Execute all au3 scripts in T-12_Software folder
Execute _Cleanup.au3
Copy _Startup.au3 to @WindowsDir
Hide _Startup.au3 in @WindowsDir
Add _Startup.au3 to the registry
Close Deployment.log in @WindowsDir

T-00

Open Deployment.log in @WindowsDir
Execute all au3 scripts in T-00_Software folder
Close Deployment.log in @WindowsDir

Active Desktop

Execute _Startup.au3 in @WindowsDir


This picture displays how executing Deployment.exe looks with the default background. The software list on the left scrolls up as each is installed. The orange font shown is the current installing application.

billboard.png

The Deployment script source requires atleast AutoIt v3.2.0.1 to compile which is available here for download. This script is a cutdown version of a deployment script that I have been using for quite some time. The installation scripts I use are created from CMenu templates for ease. Currently, this Deployment script should be a good introductory method that displays that AutoIt3 scripts can do basically anything you want them to do.

Download Links

Latest Compiled Executable and Helpfile download here
Latest Deployment script can be viewed here