Chocolatey (a Windows package manager) started out very much a thought experiment and has since become very popular. Let's dive in and learn how this happened and where Chocolatey is going next. We'll also demo some *hopefully* "fringe-y" areas of Chocolatey showing how to create package and set up your own private package server.
2. Rob Reynolds
• Developer at Puppet Labs
• Creator of Chocolatey
• All around nice guy
• Making your Windows world
a better place for automation
• .NET MVP (whatever that means)
3. Agenda
• What Is It?
• How Did Choco Begin?
• Fringe / Success / Mainstream
• “Fringe-y” Demos on Creating
Packages & Hosting Your Own
Package Server
6. Package Manager for
Windows
• Behaves much like yum
• Microsoft validated
• Technologies: PowerShell
+ NuGet packaging framework
• Does not violate distribution
rights
Chocolatey
7. chocolatey.org
• Community feed
• Community maintained
• Trust issues?
• Recommendation: A
business should run
their own internal feed
12 Million Downloads!
11. What I Wanted in 2011
• Pairing / troubleshooting experience - No
Notepad++?
• Experience with silent installers
• Existing?
• How to globalize?
12. Experiment in March 2011
• Building onto NuGet
• Packages tagged “chocolatey” on nuget.org
(until Sep 2011)
• Concepts of KISS packaging
• Building on an existing ecosystem
• Focus on UX
13. The Experiment Was Built
In PowerShell
• PowerShell?!
• Built with PowerShell
as a programming language
• Always felt like I was relearning it
14.
15. There were some good
parts
• Added Mocking to Pester
• Defined some ideas of semi-maintainable
PowerShell source code
• I learned PowerShell this time for real. Maybe.
16. And… Community
• Somewhere along the line came the community
• Design or Sheer Luck?
• Maybe it was the semi-okay Documentation?
• 1. Gnomes. 2. ??? 3. Profit!
17. Microsoft Got Involved
• Validated the idea
• Adding/added OneGet or whatever it’s called
today to Windows 10.
• Chocolatey is semi-builtin to next version of
Windows!
18. That Seems Successful
• Microsoft Involvement, Sort of Getting Into
Windows
• Except POSH code…
• …and not meeting user wants and needs
19. Long Overdue Rewrite
• Started around March 2014.
• C# - b/c I already learned about writing
production code in a language I didn’t know
that well.
• But addressing longer term existence of
choco?
23. Where Is Choco Going?
• Enhance packaging - NVRA
• Try to keep KISS while adding more complex
scenarios
• Package signing (GPG)
• Pro Version - Kickstarter Enhancements
(Stability / Virus Checking)
25. Host Chocolatey Packages
• Now it’s easy to set up
your own package feed
• Make it custom/internal for
business purposes.
• chocolatey.server package
• Beta
• Simple server
27. packagename.nuspec
• This is a nuget
packaging
specification
• Later: choco
adding
infrastructure, os
versions, etc
28. chocolateyInstall.ps1
• Helpers / Functions
• Reduce work
• PowerShell, you
can
do anything
• Function reference
http://bit.ly/
chocolateyfunction
reference
29. Create Packages Visually
• Nuget Package Explorer
(choco install
nugetpackageexplorer)
• Ignore its warnings, it is
geared towards NuGet
proper
• NO content folder