Post Package Install event?

Dec 4, 2013 at 1:26 PM
Edited Dec 4, 2013 at 1:29 PM
Hi, I need to kick off a powershell script, once my package has finished installing - If I understand it correctly, I can't just add this to the bootstrapper script, as once a reboot has happened - this script is no longer being executed?

Is there any way I could pass in a post-execution event - so once it's finished installing the package, it could kick off another package, powershell script, bat file etc?

Note: I need complete separation between the inital package (contents are 'generic' and hosted publicly as a gist) and the following package / script - as this contains business-specifc scripting.

Many thanks (it's an awesome tool by the way).

Dec 4, 2013 at 4:36 PM
Hi Mark,

How about creating another package for the post script that calls your gist script first? The first line of that script would be Install-BoxstarterPackage <gist url> followed by your business specific script.

Would that work?
Dec 4, 2013 at 5:01 PM
Hey Matt - thanks for coming back to me.

Yep - I really should have thought harder about that one :-)

The only issue I might have is that my business specific powershell needs to ask for input. Am I right in thinking this isn't something I can do from a package (I have tried this, but figure I might be missing a setting somewhere).


Dec 4, 2013 at 8:07 PM

You should be able to accept input from a package. Usually it is not advisable because people expect chocolatey packages to be silent. However, if your intent is to accept input, that should be fine. Let me know if that does not work as you expect.