In my blog post Virtual Router for Multiple Hypervisors I’m using Powershell to setup an isolated environment with internet access.
When I was creating a Task Sequence for an Virtual Router in my Automation Framework I also wanted Devolutions Remote Desktop Manager and Microsoft Remote Desktop Manager to get installed as well.
To be able to do this in MDT you need the unattended install string, but my research only lead my to Chocolatey. Say what!
So to get started you first need to install Chocolatey – Run cmd.exe as an Administrator and paste in the following command:
1 |
@powershell -NoProfile -ExecutionPolicy unrestricted -Command "iex ((new-object net.webclient).DownloadString('https://chocolatey.org/install.ps1'))" && SET PATH=%PATH%;%ALLUSERSPROFILE%\chocolatey\bin |
Now let’s try that strange command:
1 |
choco install rdm |
Wow, did you see that? That command line automatically downloads the latest version and installs it unattended, how cool is that?
Setup Commander can do the same and also automatically integrates with MDT / SCCM, but that’s the Enterprise Version and this Chocolatey tool is free.
You know, software is like rotten tomatoes. Flash, Java, Chrome etc gets updated at least every 2nd week.
Okay so now that Chocolatey has my complete attention. How can I get this to work with my Automation Framework? After doing some research I found a Chocolatey Wrapper for MDT, grab it here Chocolatey Application Wrapper for MDT.
Create a Task with Powershell and use the following parameters:
1 |
-verbose -Packages "rdcman","ghostscript","rdm","cutepdf","javaruntime","flashplayerplugin","flashplayeractivex","adobeshockwaveplayer","silverlight","adobereader","vlc","sysinternals","skype" |
So every time I create a new Master Image machine it will always have the latest and greatest software version installed.
What about security? Would you use this in Production or is it just awesome for lab and PoC? Please leave a comment and let’s discuss.
Chocolatey is gr8 for Lab usage.
Would never bring that into prod environment.
Thanks Markus.
Since you can set up a private Chocolatey server with your internal company specific packages, I see no issue from security perspective.
I agree Frank.
Hey Trond
The choco packages in the example above, are those sources/binaries hosted in the cloud on the Chocolatey servers or within the MDTProduction\Applications folders?
Those are cloud hosted, will work on a Getting Started with Chocolatey and Boxstarter article today.
hello! curious to your take on this now that its a few years later.
this has taken off in production(free ver), and I worry about it hitting sources such as GitHub, sourceforge, etc.
right now our issue is w/ the forced reboots, hoping your MDT wrapper fixes that! thanks