powershell package management for the enterprise kirk munro @poshoholic [email protected]...

24
PowerShell Package Management for the Enterprise Kirk Munro @poshoholic [email protected] Aleksandar Nikolić @alexandair http:// www.powershellmagazine.com

Upload: dwayne-berry

Post on 18-Jan-2016

216 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: PowerShell Package Management for the Enterprise Kirk Munro @poshoholic poshoholic@gmail.com Aleksandar Nikolić @alexandair

PowerShell Package Management for the Enterprise

Kirk Munro@[email protected]

Aleksandar Nikolić@alexandairhttp://www.powershellmagazine.com

Page 2: PowerShell Package Management for the Enterprise Kirk Munro @poshoholic poshoholic@gmail.com Aleksandar Nikolić @alexandair

#MMSMOA

@poshoholic

Technical Product Manager

*Px modules, pull

requests, and more

Almost 19 years working professionally

with technology

8-Time PowerShell

MVP

World’s first self-

proclaimed Poshoholic

Shédiac, NB, Canada

Kirk Munro

Page 3: PowerShell Package Management for the Enterprise Kirk Munro @poshoholic poshoholic@gmail.com Aleksandar Nikolić @alexandair

#MMSMOA

@alexandair

Freelance PowerShell and Azure trainer

PowerShell

Azure

A cup of tea

Microsoft MVP

Serbia

Aleksandar Nikolić

Page 4: PowerShell Package Management for the Enterprise Kirk Munro @poshoholic poshoholic@gmail.com Aleksandar Nikolić @alexandair

DISCLAIMERPowerShell Package Management is still very, very new

Page 5: PowerShell Package Management for the Enterprise Kirk Munro @poshoholic poshoholic@gmail.com Aleksandar Nikolić @alexandair

Let’s talk about OneGet

Page 6: PowerShell Package Management for the Enterprise Kirk Munro @poshoholic poshoholic@gmail.com Aleksandar Nikolić @alexandair

OneGet is…

…a package management aggregator…an open source project on GitHub

It consists of…

…a core API for software discovery, installation and inventory (SDII)…a PowerShell module that wraps the core API…a collection of package managers

OneGet

Page 7: PowerShell Package Management for the Enterprise Kirk Munro @poshoholic poshoholic@gmail.com Aleksandar Nikolić @alexandair

OneGet

…is now called PackageManagement…because lawyers were asked if the name was ok…and of course they found a reason for it not to be…and MS Pac Man didn’t fly as an alternative

Page 8: PowerShell Package Management for the Enterprise Kirk Munro @poshoholic poshoholic@gmail.com Aleksandar Nikolić @alexandair

PackageManagement is…

…a package manager aggregator (a meta-manager)…an open source project on GitHub (where it is still called OneGet)…available natively in PSv5 and in preview for PSv3 and PSv4

It consists of…

…a core API for software discovery, installation and inventory (SDII)…a PowerShell module that wraps the core API…a collection of package managers

PackageManagement

Page 9: PowerShell Package Management for the Enterprise Kirk Munro @poshoholic poshoholic@gmail.com Aleksandar Nikolić @alexandair

What Package Managers are available?

Page 10: PowerShell Package Management for the Enterprise Kirk Munro @poshoholic poshoholic@gmail.com Aleksandar Nikolić @alexandair

Included in OneGet

MSIMSUPrograms (Add/remove programs, remove only for now)BootStrap (not visible, for automation only)

Also available

NuGet (bootstrapped off the web)Chocolatey (included with NuGet)PSModule (installed with PowerShellGet)Gist (@dfinke)Cygwin (@poshoholic)

Package Managers (aka Package Providers)

Page 11: PowerShell Package Management for the Enterprise Kirk Munro @poshoholic poshoholic@gmail.com Aleksandar Nikolić @alexandair

Future Package Managers (ideas/wishlist)

Windows Update (WSUS catalog, Windows Update and Microsoft Update)Windows StoreRuby GemsNode’s NPMPerl’s CPAN

PythonVSIXAppVWebPISCCMWindows Featuresand many more…

Page 12: PowerShell Package Management for the Enterprise Kirk Munro @poshoholic poshoholic@gmail.com Aleksandar Nikolić @alexandair

DemoPackageManagement

Page 13: PowerShell Package Management for the Enterprise Kirk Munro @poshoholic poshoholic@gmail.com Aleksandar Nikolić @alexandair

What is PowerShellGet?

Page 14: PowerShell Package Management for the Enterprise Kirk Munro @poshoholic poshoholic@gmail.com Aleksandar Nikolić @alexandair

PowerShellGet

PowerShellGet is a module that depends on (and ships with) PackageManagementIt consists of a Package Manager (provider) and a PowerShell module that provides a provider-specific set of commands

Page 15: PowerShell Package Management for the Enterprise Kirk Munro @poshoholic poshoholic@gmail.com Aleksandar Nikolić @alexandair

DemoPowerShellGet

Page 16: PowerShell Package Management for the Enterprise Kirk Munro @poshoholic poshoholic@gmail.com Aleksandar Nikolić @alexandair

Strategies in PowerShell Package Management

Page 17: PowerShell Package Management for the Enterprise Kirk Munro @poshoholic poshoholic@gmail.com Aleksandar Nikolić @alexandair

Strategies in PowerShell Package Management

Use code signingUse source control (git/GitHub work very, very well)Work with unsigned script files day-to-daySign files only when you publish a releasePlace signed release versions on a separate branch in source controlBuild an automated publishing pipeline

Page 18: PowerShell Package Management for the Enterprise Kirk Munro @poshoholic poshoholic@gmail.com Aleksandar Nikolić @alexandair

Why PowerShell Package Management for the Enterprise?

Page 19: PowerShell Package Management for the Enterprise Kirk Munro @poshoholic poshoholic@gmail.com Aleksandar Nikolić @alexandair

UsabilityControl what modules are availableControl where modules are made available from

Set up an Enterprise repository that offers only approved/verified scripts and modules

SecurityControl what scripts users can run

Leverage features like AppLocker and/or Device Guard to provide security over scripts and modules

PowerShell Package Management for the Enterprise

Page 20: PowerShell Package Management for the Enterprise Kirk Munro @poshoholic poshoholic@gmail.com Aleksandar Nikolić @alexandair

Options for Enterprise PowerShellGet repositories

UNC share• Pros: on premises, trivial to set up• Cons: lacking features available in full repositories (UI, branding, tags, etc.)

Local NuGet installation• Pros: on premises, feature rich, open source, brandable and fully customizable• Cons: much more complicated to set up initially (for now)

Page 21: PowerShell Package Management for the Enterprise Kirk Munro @poshoholic poshoholic@gmail.com Aleksandar Nikolić @alexandair

Options for Enterprise PowerShellGet repositories

ProGet• Pros: on premises, commercially developed, free tier available• Cons: paid tiers required for larger teams/enterprises, may be more than necessary for PowerShell Package Management

MyGet• Pros: commercially developed, free tier available (open source only)• Cons: paid tiers required for closed source projects, hosted servers not allowed in some enterprise environments, may be more than necessary for PowerShell Package Management

Page 22: PowerShell Package Management for the Enterprise Kirk Munro @poshoholic poshoholic@gmail.com Aleksandar Nikolić @alexandair

DemoSetting up a local PowerShellGet repository

Page 23: PowerShell Package Management for the Enterprise Kirk Munro @poshoholic poshoholic@gmail.com Aleksandar Nikolić @alexandair

Evaluations: Please provide session feedback by clicking the EVAL button in the scheduler app (also download slides). One lucky winner will receive a free ticket to the next MMS!Session Title:

Discuss…

Ask your questions-real world answers!Plenty of time to engage, share knowledge.

SPO

NSO

RS

Page 24: PowerShell Package Management for the Enterprise Kirk Munro @poshoholic poshoholic@gmail.com Aleksandar Nikolić @alexandair