Build Private PowerShell Gallery

Build Private PowerShell Gallery

Hello,

A few months ago, Microsoft released the PowerShell Gallery, this a website that you can use with “PowerShellGet” (OneGet) PowerShell module to download modules published and shared by the community :

Find-Module IseSteroids | Install-Module

This is great, the greater part of it it’s that Microsoft will allow us to host the same thing in our private Datacenter. They published the sources on GitHub :

https://github.com/PowerShell/PSPrivateGallery

Build Private PowerShell Gallery – Steps

Build Private PowerShell Gallery

Build Private PowerShell Gallery

  1. Download the project
  2. Unzip it
  3. Copy the modules from the project to “$env:ProgramFilesWindowsPowerShellModules”
  4. Generate the credential files : Get-Credential | Export-Clixml GalleryAdminCredFile.clixml (both user and admin)
  5. Update the PSD1 files to fit your need (URL, Name, Path, etc…)
  6. Deploy the Gallery with “PSPrivateGallery.ps1” (DSC)
  7. Then, run the last script and you’re good to go !
Build Private PowerShell Gallery - HomePage

Build Private PowerShell Gallery – HomePage

Note : As you can see, this project is in preview, and should not be deployed in production right now.

Leave a Reply