Thoughts around PowerCLI and the Powershell Gallery

I am *very* excited to share some thoughts and possibilities for PowerCLI.

Packaging and Installation are big areas we have been looking at. We have heard loud and clear that our customers wanted to embrace modules and in our recent releases we have moved away from snapins into modules. We’re now looking at how we package the modules and deliver them to our users.

One possibility would be releasing PowerCLI exclusively from the Powershell Gallery, the central repository for Powershell modules. The benefits of this would be great, as it provides easy installation and upgrade, follows Powershell patterns for modules, and most importantly would allow us to deliver PowerCLI to multiple platforms, such as Linux and MacOS.

Here is an idea of what we are currently thinking:

  1. You would need to make sure you have the latest Powershell. WMF 5.1 is required for the PowershellGet cmdlets, which includes install-module. (You may want to do this now!)
  2. Make sure $env:PSModulePath includes C:\Program Files\WindowsPowerShell\Modules . This is only precautionary because it should already be set, but you should check anyway.
  3. Prior to installation of the PowerCLI from the Microsoft Gallery you would need to uninstall any previous version of PowerCLI that was installed by MSI.
  4. You would no longer have PowerCLI shortcuts on your desktop. PowerCLI would be immediately available when you run powershell, no Import-Module required. If you really miss the icon, find me at a conference and I’ll give you a sticker! 🙂
  5. Installation of PowerCLI on machines that cannot access the Powershell Gallery can be done by saving the module to a thumb drive or network share accessible to the installation target and dropping the files in the module folder of the destination computer or using Install-Module with a path to the downloaded file.
  6. We are thinking about using Update-Module in the future to make geting the latest bits faster and easier!

I understand that change can be hard, so I’m giving you the opportunity to tell us why (or why not) a Powershell Gallery installation/update would not work for you.

Regarding the results from the survey we recently held, an extremely high percentage of the respondents prefer the Gallery installation for ease of installation and updates. Still, there were a few respondents that had some concerns that I want to address here.

  1. “The Powershell Gallery is not as secure as downloading an MSI from vmware.com” – This is not true. We digitally sign all PowerCLI files as we always have, guaranteeing authenticity. PowershellGet has built-in verification of the digital signature, and will not install unsigned modules unless you explicitly skip the publisher check.
  2. “This makes offline installation/upgrades much harder” – So far, I’ve identified two different methods of offline installation and both require less steps (and ZERO mouse clicks). Method one uses Save-Module to copy to a network drive accessible by the ‘offline’ machine. You could also save to a USB drive or any other storage location that your installation target can access. Method two uses Invoke-WebRequest to download the package and can again be saved to a location of your choosing. Either of these options are still far easier than the current process.


In my prior life as a customer, I could only dream of installation and upgrades being this easy. By releasing to the gallery, it would not only make *that* dream come true, but would also give us the ability to accelerate our releases to get improvements out for you to enjoy much sooner.

Added to this we would be bringing PowerCLI back in line with the PowerShell patterns and ensuring future powershell enhancements made around modules and module tooling could easily be consumed with PowerCLI.

I hope you join with me in the excitement of the amazing opportunities we have with PowerCLI!

What are you excited or concerned about with a Powershell Gallery release? Let us know in the comments here!



28 comments have been added so far

  1. Hi Jake,

    absolutely looking forward to that move.

    When you change the way this works, would you mind improving the compatiblity of PowerCLI with the rest of the PowerShell ecosystem?
    – The current module changes a lot of the user’s environment (prompt and tabexpansion).
    – When importing PowerCLI, lots of child-modules get loaded that are completely superfluous. All of that content could be part of the main module.
    – The manifests declare “*” as the exported functions/cmdlets. Explicitly list all cmdlets and functions instead to have less impact on performance.
    – You ship a lot of customized Get-PrefixCommand functions that give no extra value over Get-Command.


      1. I’ve got your previous version customized doing much of that already. If you’ve got me a place to dump the current version, I can send you the changes:
        – Dropped the prompt change
        – Did most of the consolidation
        – Fixed the manifests

        1. Okay Fred, Now that we’ve released 6.5.1, I’m looking forward to see if we missed anything in your list. 🙂 My email is jaker at vmware

  2. I also prefer the PowerShell gallery approach. Still, I wish yah’ll would do something about the cmdlet naming overlap with Hyper-V cmdlets.

  3. While I like the Microsoft Gallery approach in general you might have problems in certain market segments such as DoD where there are strict requirements of getting software from secure, trusted and verify sources. I don’t know if the Microsoft Gallery would be able to be used in those situations.

    1. Hi Judd, Microsoft is working closely with DoD type segments to get the gallery verified. Microsoft is fully invested in distributing powershell modules using the gallery.

      1. It is over a year later and Powershell Gallery is still blocked by the DOD and I expect it to remain that way as long as the powershell gallery allows third-parties (and that includes VMware) to post modules. The DOD is never going to allow any site that does not guarantee every module on the site to be safe. Microsoft is never going to guarantee third-party modules.

        VMware does not have to provide an MSI, only a zip file on their site to satisfy a single source, guaranteed safe download that would satisfy DOD requirements.

  4. While I like the idea of simplifying the installation I would like a way to download it straight from VMware as well.

    The proxy servers at work won’t allow me to download things from the Microsoft Gallery so I would have to download it off the network and send the files to myself which would be tedious.


  5. My concern would be the requirement to have WMF 5.1 installed. Unfortunately at work we have WMF 3.0 installed which prevents 5.1 from being installed.

      1. I work in a large corporation and do not control what Microsoft updates are installed on my workstation.

        Most of your customers are ENTERPRISE users, not home bloggers. In the Enterprise world there are things like Proxy servers, Firewalls, and standard desktop/VDI images to worry about.

        1. Hey Tacos, I’m sorry you’re not enjoying the new packaging and distribution method. I’ll share my perspective and dig in with some more questions to help me understand your situation.

          Firstly, on ‘home bloggers’: Careful… most of them are enterprise customers and partners with the same constraints in their own organizations.

          Is it the fact that the gallery is not a microsoft.com or vmware.com domain? If so, does your organization not have a procedure for whitelisting sites or repositories?

          Some enterprise customers who utilize Powershell as an organizational strategy are opting for their own private gallery. This allows them to distribute approved public modules across their workstations, and also distribute their own scripts and modules in a secure, consistent manner.

          Can you share your perspective on why the Microsoft Powershell Gallery is NOT ENTERPRISE? I hate for any user to have a bad time, and I want to do what I can to help you be efficient and automate the world.

          Here’s my perspective on why releasing to the Microsoft Powershell Gallery is MORE ENTERPRISE than an MSI:

          1. The Gallery will allow us to have a single installation method across all platforms (Win, Linux, MacOS).
          2. The Gallery allows us to release individual modules. This means we don’t have to do a full MSI package for a single module update.
          3. Smaller, more frequest releases means more developer focus on features and less on packaging and release problems.
          4. Simplified releases to the Gallery means less of a release bottleneck, and gets you PowerCLI awesomeness faster.
          5. The update-module cmdlet means you get the latest features and value in a single command.
          6. Finally, Microsoft is investing an epic amount of money to make this the de-facto standard for distributing Powershell modules. NuGet and PowershellGet are shipping standard with WMF 5.x, and I heard that PowershellGet is supported back to WMF 3.x.

          Thanks for your feedback. Please know that I am listening to all feedback that comes my way, and everyone is heard!


          1. I’m in a secure environment which doesn’t allow direct or proxied downloads at all. Just saying “use a proxy” isn’t an option. I NEED an offline install mechanism.

        2. Also, in regards to Proxies, I just confirmed on my own machine that Register-PSRepository, Install-Module, and Update-Module all have -proxy and -proxyCredential, allowing you to install modules through an enterprise proxy!

  6. Thanks for sharing the details. The proxy servers at work won’t allow me to download things from the Microsoft Gallery so I would have to download it off the network and send the files to myself which would be tedious

    1. Is it because you require a proxy, or that powershellgallery.com is not whitelisted? (there are -proxy arguments for cmdlets like Install-Module). Additionally, if your organization uses powershell as a strategic advantage, running your own private gallery locally is a great option.

  7. This would be totally awesome.

    I already created a custom module for our team to short-circuit waiting for the vSphere GUI to load which can help them find, turn on and connect to test servers.

    Would really benefit others if this sort of thing was available via PowerShellGet rather than after installing more things

  8. Thanks for visiting VMUG Indy yesterday. Installing from PowerShell Gallery is really cool!
    Here the top things I’d like to see included in the Horizon module (not have to download community extensions):
    Get-HVSession (logged on users)
    Let me know, and I can elaborate more. Thank you.

Leave a Reply

Your email address will not be published. Required fields are marked *