PSAppDeployToolkit - What is it and why do we use it? - written by Donald Leckie
What is the PSAppDeployToolkit?
The Powershell Application Deployment Toolkit or PSADT is an essential tool for the Application Packaging team at Workspace IT, not one day goes past without it. It is a powerful and robust wrapper, that I would encourage anyone who is into application packaging or application deployments to spend a little time getting familiar with.
What does the PSAppDeployToolkit do?
Well, if delivered as part of the payload or installation media of an app package, it can be used to control the installation. If you have multiple MSI's with MST's you can script them all in order and just call the overarching executable at launch and it will take care of the rest. Same if you have a few executables with various prerequisites. Yes, I did say "script" it, so why is it better than VBScripting, Command Prompt, or just plain Powershell? Well, let me answer by explaining why we use it.
Why do we use PSAppDeployToolkit?
PSADT is a very complete toolkit that already has inbuilt features for many scenarios that an applications packager will likely experience on a day to day basis. For example, there is an inbuilt command that can uninstall all versions of a particular application by name without needing the relevant MSI product code. You can use PSADT to copy files or directories into user profile locations at the point of install, meaning that you don’t have to wait for a reboot or for something like active setup to come in and copy those files in place. Similar tasks can be performed with user registry values.
Admittedly, this could all be done through any of the aforementioned scripting methods, so PSADT isn't really doing that much new if you look at it from a certain perspective. What it does do though, is it simplifies and puts all these options in one place. If you include PSADT as part of your packaging template, you will ensure a greater level of consistency and your method and process, and it makes future updates to an application package simpler and more straightforward.
Favourite Features
Two of my favorite features of PSADT are the logging, and the customization:
The logging is consistent and easy to read. It clearly tells you the exit codes or what is wrong with your package. Error handling is fairly robust, and the exit codes are well documented online. This makes PSADT easy to learn and troubleshoot. Customization isn't necessary for every application, but it is important if you have multiple customers with different requirements.
At Workspace IT we place our customers' needs and wants at the forefront of any solution. We have packages which deliver silently for the majority of customers, but we also cater to customers where an update to critical software at a time where they are using it could lose them their work. For this, we use PSADT to prompt users to check if it is ok to install, even if the deployment tool would otherwise allow it. And even yet, we have some niche or bespoke applications which just will not install silently or conventionally at all, and in some instances we have to rely on Send-Keys functionality to get the job done – again this is built in to PSADT should you require it. Custom dialogue prompts can be used to reassure the user as this is happening, if it is necessary. It isn't always pretty, but we can use it to get the job done where others can't.
Ultimately, I feel that PSADT is a value add to any App Packager who gets to know it. It works with most deployment platforms such as Config Manager, Intune or ManageEngine, so will be suitable for most environments. It can be as hands off or as hands on as you need it to be. I feel that it is a useful arrow in an application packager's quiver, and with the years of work that has been put into it already making it an excellent tool, and the stewardship it has received from PatchMyPC, I look forward to see what we can do with PSAppDeployToolkit next.