Interview with Rob Reynolds (Chocolatey) and Matt Wrock (Boxstarter) on couch : Build 2018

– Hello, everybody Welcome back to Channel 9 Live here at Build It is lunchtime, and what better topic to talk about than chocolate? [ Laughing ] We are here with Matt, Rob, and Yosef, and we’re here to talk about some things that we heard yesterday in the day two keynote Namely, Chocolatey and Boxstarter So, welcome to Channel 9 Excited to have you guys here and learn a little bit more about it Why don’t we quickly introduce both of you, and Yosef, yourself as well? And tell us why you’re here Who are you? – I’m Matt Wrock I wrote Boxstarter – OK, great – I’m Rob Reynolds I founded Chocolatey Software I’m the one that started it all about seven years ago – I’m Yosef Durr I’m a PM lead on a few developer tools – And Yosef works on WSL as well We’re sporting our WSL shirts – That’s right, we’ve got our WSL shirts on, yeah – That’s great – That’s right – OK, so I know what Chocolatey is I was there from the beginning I’ve used it before I don’t know what Boxstarter is Help me understand what the relationship is Where do they work? Maybe let’s start with — maybe people don’t know what Chocolatey is, too So maybe let’s start, Rob, with you can just give us, like, what is Chocolatey? What is it? Share for us – We can do the quick So, Chocolatey is basically software management for Windows or package management, some people want to say You know, it can go for — you want to get some software installed It really allows you to rapidly do that, right? And then be able to also upgrade it very rapidly and just continue to make sure that you have that software up to date And it goes beyond programs and features, right? It’s like all aspects of Windows software are first-class citizens with Chocolatey, so it’s your zips, your scripts, your runtime binaries, oh yeah, and your installers, too It does all of that, manages it You get the good reporting, all that good stuff – That’s awesome And so how does Boxstarter come into play here, then? – You can kind of think of Boxstarter as a wrapper around Chocolatey Oh! I didn’t even plan that, a Chocolatey wrapper [ Laughing ] – We’ll be here all week – They exist kind of spontaneously, yeah When I initially wrote Boxstarter, I was actually inspired by a hard drive failure I’m sure we’ve all had the experience where we’re working on our dev box and then just, like, sudden death For example, two weeks ago, my motherboard died on my personal laptop That was a bit of a bummer So you’re in a situation where you need to rebuild your box, and if you’re in the business, if you’re a developer, that’s productivity, right? – Right – That’s hours, days possibly, of time, not only going through the process of the next-next-finish, but also just trying to remember, like, “What do I click next-next-finish on?” And so, around this time, I thought, honestly, there’s got to be a better way There’s got to be a better way where I can just launch a script and just come back and have everything be there – Like every software developer, you started writing the better way – Right, exactly Yeah, totally Yeah, it was that or a blog [ Laughing ] So, at any rate, around the same time, I discovered Chocolatey I remember, this is like 2012 I had discovered Chocolatey months before, just didn’t quite get it, and now I totally got it And so Chocolatey gave me exactly what I needed to install individual pieces of software, but what I needed on top of that — I needed SQL Server, I needed Visual Studio, and especially It gets better each year, but back in 2012, there’s three reboots right there – Yes – So I needed – Yeah, you had to go find those things, gotta go download them – Right Well, so that’s what — Chocolatey takes care of that for you – Right – But then, what wasn’t being taken care of is, is there a pending reboot? You know, so if I do a Chocolatey install, a choco install of Visual Studio, is it going to fail because there’s a pending reboot? And then, I had to be there to reboot my machine, to log on to my machine – OK – So basically what Boxstarter does is it wraps around a bunch of Chocolatey installs and allows you to — it basically detects reboots and can actually automatically reboot your machine So you literally can walk away, have a cup of coffee or have dinner or maybe sleep a night and come back and have your machine be the way that you want it to be – OK, that’s great Yesterday, we saw mentions in the keynote Maybe, Yosef, you can tell us – Yeah – What is this collaboration with Windows and Chocolatey? – Yeah, really the driver for this is a few things For myself, as a developer, I get tired of having to set up machines And this is a great suite of products here that these guys in the community have built,

and so we want to recognize that And so, using Build as a time to recognize this The other thing is, to give an example, I was at a Node conference last fall, and people are spending too much time setting up their Windows machines You know, it was a new space for them to make their first pull request to Node to contribute to it And for me, it was like, well, that doesn’t need to be that way Let’s go fix this And so this is about really collaborating on making it so we can get out of the business of setting up machines and really focus on the work once we’re up and running, especially in this world now where we have so many interesting tech stacks and sessions that we’re looking at We shouldn’t have to pay the tax of learning the setup process for that stack We should be able to just click once, grab a coffee, come back, and go do the Hello World of that stack, and so that’s where I see this going And the collaboration, it should be a lot of fun and very rewarding, I think – And we’ve talked a lot about, you know — the message that we’ve talked about from a Windows developer perspective is that Windows is a great dev box for everyone – That’s right – Right? We briefly mentioned WSL and things like that But as we think about developers — and I’m sure, Rob, when you started Chocolatey, this was the problem you were trying to solve As developers, we’re like, “Well, yeah, I need my core IDE, but I also prefer this thing and this library, and I want it this way, and by the way I need these four other things.” You know, and then you get your sweet new machine and you’re like, I gotta repave or whatever, and it’s like, “I gotta go do all that crap again!” You know, I’ve had those experiences before, and so everyone has their own personality of what their dev box means and what their productivity tools mean – Absolutely – And now you guys provide a means for us to more quickly get that – That’s right – Now, can I, through Chocolatey — I’m an organization Now, let’s say I have a specific perspective on what my org’s dev box machine will be Is that something that I can kind of configure as an uber script and kind of manage a little bit better? Maybe I manage it through Boxstarter How might that work? – Yeah, absolutely Chocolatey in an organizational context is maybe a little different What you see at chocolatey.org, we have a community repository, right? It’s got all these packages that are maintained and moderated by our community When an organization is using Chocolatey, typically they’re going to set up their own internal repository They’re going to create packages there They may pull some packages from that community repository, go through this process that we call internalization, where basically they’ll remove all internet need for those packages at run time So, because those packages on that community repository are in a public domain, right — or not public domain They’re in the public, so they get subjected to distribution rights, copyright law, so they can’t always contain the software that they represent – Right – So they have to reach out, download it from the internet at run time And when you’re an organization and you’re doing stuff, you want to have everything inside, right? You don’t want it to reach out to the internet at run time You want more reliability right? And so typically they set it up a little differently Yeah, they could absolutely set up Boxstarter, point it to the inside They could use Chocolatey with that They could use it with other tools as well, so SCCM — I hope I’m saying that right — or Puppet, Chef, Ansible, Salt, all those different types of configuration management type things But also, really anything that can run scripts can direct Chocolatey, can direct Boxstarter, to do what it does – That’s really fantastic We’re here again talking about Chocolatey and Boxstarter on Channel 9 Live Be sure to submit your questions, log in and ask questions You can ask a question below from the stream here, and also send it to us at @ch9 on Twitter Why don’t we take a look at a demo and see how some of this works, if that’s OK? – Oh, sure, yeah – We just happen to have a computer here Let’s do a demo – That’s right, yeah And just if I may, just to tie in on kind of that organizational scenario, too – Yes – To be clear, when I wrote Boxstarter, I was writing Boxstarter for me and my fellow developers And the great thing about Boxstarter is I wanted it to be super simple I wanted there to be very little learning curve So Boxstarter does a great job of setting up my personal laptop It might not do a great job of setting up my fleet of servers So, like Rob mentioned, there’s other tools out there that work great with Chocolatey I personally work for Chef Software, and so we work great with Chocolatey at setting up a fleet of Windows boxes You know, Rob used to work for Puppet But let’s dive into, you know, what is this like? – Yeah – So I want to get something set up on my dev box There’s a multitude of different types of scenarios

As I mentioned, the key scenario for me personally as I was writing Boxstarter is I am coming to fresh OS, right? Like, all I have is an operating system, and now I want to put everything on there and walk away And everything could be a collection of Chocolatey packages, but it could also be some other things I have some ways that I want to personalize my machine For example, I want to set up my Windows Explorer to show me all the folders For example, I want to see program data I don’t get that by default I want to see file extensions I want Windows updates to install So let’s actually take a look at Are we seeing my screen? – Yep – OK, great What we’re looking at here is the GitHub project that was announced the other day, and so let’s take a look at some of the sample scripts – And what we’re looking at here is the GitHub project that is part of this collaboration, kind of identifying How should I think about this script? Is it a Chocolatey script? Is it a Boxstarter script? – This is basically a repository of Boxstarter scripts, and so you bring up a great point Like, what do you mean, Boxstarter script as opposed to Chocolatey script? – Right – So, to be clear, a Boxstarter script is a Chocolatey script And what is a Boxstarter script? It’s exactly this Let’s look at one It’s PowerShell It’s 100 percent PowerShell And not only can I call PowerShell commandlets — so here I’m doing some registry tweaks up here — but I also have access to the Chocolatey CLI that I’m calling here – Got it, OK – Basically, anything that I can do on a command line, I can do in this script that we’re looking at – What we’re looking at here in this particular script, you mentioned the File Explorer one, and I see that on the screen – Yes – The set item property So these are PowerShell commandlets that are basically running or that you are executing in this context, and then followed by there were some just straight up Choco install commands – Right, exactly – They’re like, “Go get me this software.” – Yeah, configure my machine this way and go install these things And at the very end, the other thing that we do is we install Windows updates, and as some of us know Here, what I’m going to show is – We don’t have time for that – Yeah, exactly We absolutely don’t have time for it And so, on a Windows 10 box, there’s going to be a lot less updates If you’re doing a Windows 7 box, yeah, it’s a multi-hour experience – The one thing that this setup doesn’t do is — well, it’s a question It doesn’t install an OS – It does not install so this is not a – The assumption is I’m starting from an installed operating system – Right, exactly – Domain join, maybe Or, I don’t know, can I run a script that does domain join? – You could domain join, but yeah, this does operate under the assumption that you have an operating system – I’m logged in, and now I’m getting myself set up – Right, so this could be a tool in your provisioning stack, but it’s not the entirety of your provisioning stack – OK – Yeah, you still need to raise up an OS – So that’s a look at the script – Yeah, so let’s take a look at this script real quick You know, this can be as big or as small as you possibly want This is doing some tweaks to the Windows Explorer It’s going to install Hyper-V, so this can install You can notice that we have a source There’s several different sources of Chocolatey packages The default will be to just pull off Chocolatey packages from the community feed – OK – But this is a special source, Windows feature Basically, these are the exact same string or token that I could feed to — some users out there might be familiar with DISM, for example – Right, a setup assistant – Exactly That’s what this is doing underneath the hood It’s setting up these Windows features It’s going to install Visual Studio, the community edition of 2017 Sysinternals, which are a great set of tools founded by Mark Russinovich And it’s going to install Windows updates and Microsoft updates – And these Windows features that we see here through the Chocolatey installer, are those things that Microsoft provided? Are these Microsoft-provided packages? – These are basically part of the operating system So, if I was on let’s say a Windows Server 2016 box and I had a PowerShell command, I could say, you know, “Add-WindowsFeature” and give it this string The tricky thing about that is that there’s a different way of calling that specific command on different Windows operating systems – Ah – So you might call it one way on Windows ’16, you know, in PowerShell You might call it another way on a Windows 10, because Windows 10 doesn’t have — they’re actually different strings And so one thing that – So here’s the benefit of Chocolatey – Right, it will do that detection for you – The package has all the information,

the metadata, and so now I just say, “I don’t really care, I just know I need this thing.” – Yeah – Give me this thing And Chocolatey kicks in and is like, OK, well I know you’re this guy, and that thing here is over here, or whatever this config, and stuff like that – Right, right – So the onus is on the author of the Chocolatey source to make sure that I put all those necessary configurations Is that correct? – Right, exactly Yes, it’s up to — you know, this script that we’re looking at here, it’s up to you, or the person that’s handing it to you It’s not up to Boxstarter or Chocolatey to write this – OK – This is something that you would author yourself The next question is, so, what do I do with this script? I have the script It says how to set things up When I was writing Boxstarter, one of my goals was I didn’t want to have to — you know, the idea was I wanted to hop on a box, on a brand-new box, and just go, basically – Just run it – And so what Boxstarter does is it also includes a click-once installer, basically – OK – You can essentially invoke Boxstarter with a URL That URL will invoke a click-once installer that will install a very small executable that will essentially then pull down several Boxstarter PowerShell modules It will also install the Chocolatey library, so all the guts of Chocolatey that can install packages for you And it’ll install .NET 4, if for whatever reason that’s not on there, and you’re good to go So what I could do and what’s provided here in the read me, is I could literally click on one of these links, and let’s take a look at this link – These are some of the examples – Right, exactly Let’s say this desktop app – OK, desktop – Yeah, so let’s deconstruct this link here real quick – This brings up a good point I think I heard the answer, but I’m going to ask you explicitly I remember when I started using Chocolatey, one of the challenges, right? You repave your box With package managers, challenge one is you need the package manager, right? It’s not convenient until that’s there – Right – And sometimes that can be a challenge You know, I gotta go get the thing And maybe I don’t have an internet connection at that time, I don’t know, or I forgot what it is, and stuff like that What I’m hearing is you saying it’s like these URLs provide a way to kind of bootstrap getting me that package manager guts and then allow me to start executing things on top of that – That’s exactly it, yeah – OK – I mean, hats off to Rob I mean, he’s done a great job with — it’s super simple to install the Chocolatey CLI – Yeah – I mean, it’s like one, two lines – We took a line from Homebrew on that guy They had the whole download something and then – Right – You know, invoke it so that it can actually do the installation – Yeah – Because the convenience is only there with package managers once it’s there, right? – Yeah, absolutely – Right now go ahead – Well, the nice thing with this script project on GitHub is we’re reusing the affordance that they’ve created so that it really is one click Even if you haven’t installed Boxstarter or Chocolatey yet, the one click and you just hit “yes,” and it goes and runs It’s, you know, hands-free That’s the beauty of it, I think – Yeah, yeah So maybe let’s kick off an install, and then while that’s working, we can answer some questions – Yeah, let’s do that There’s a simple way and a more involved way, so we’ll start off with the simple way Let’s say I already know that there’s a specific package Maybe I have a specific package that I’ve actually uploaded to the Chocolatey community that I know I want to install directly on my machine So what I can do is I can basically say HTTP Oh I can essentially do this I can say boxstarter.org/package/ — the NR is for no reboot So, by default, what Boxstarter will do is, as it’s installing software, before each step it’ll say, “Is there a pending reboot?” Oh, yes, there is a pending reboot I’m going to reboot the computer It’ll prompt you for your credentials, and so it’ll log in with those credentials Now, if I’m here Like, right now I don’t want my computer to reboot, right? – Yeah, please don’t – Because here we are That would be kind of disappointing So I can basically force Boxstarter to say, hey, I’m not interested in reboots today Now, I don’t have Firefox on this machine, and I would love to have Firefox Now, I could be pointing to a package that has a whole bunch of different installers, or I could just be pointing to an individual package In this case, just to illustrate kind of just how the basic mechanics work, I’m just going to say, “Hey, install Firefox.” And this is going to be just right on my personal laptop I’ve already hit that, and so the next thing that happens is this box comes up, so I pause things here This is, you know – This is the click-once – This is the click-once So if you’re familiar with click-once installers, you’ll recognize this I’m going to say, “Yes, please, go ahead and run.” Now, what’s doing is it’s installing Boxstarter

Basically, it’s just simply grabbing a collection of PowerShell modules and pulling them down – And I see you have signed your click-once installer, so thank you for that, number one – Yes – Still in the process on that one – Yeah, that will — yeah, it has been signed I mean, interesting that you would write that, because One thing that we’ve done, and we’ll talk about this in a bit, is we’re moving Boxstarter into the Chocolatey org – Oh, OK – So, eventually, this will actually be under the Chocolatey code signing certificate That’ll be nice, because let me tell you, maintaining those certificates – It’s tough work, yeah – It’s not tough work; it’s just a pain in the butt if you want a free one, let’s just say that [ Laughing ] – So, while this is finishing, let’s make sure we get some questions here from the audience Manfred is asking, when is the management UI due? Is this a community thing, people have been buzzing for a Chocolatey management UI? – I’ll take that So we have the open source edition of Chocolatey, and then we have some commercial-side stuff, and one of those is Chocolatey for Business His question is about the management UI or what we call Chocolatey Central Management, and this is a place One of the big things you see is, yeah, I got all of these different fleets of machines that I need to deploy to, but I have no central way of reporting on all of that information So this is about collecting all of that into one place so I get a one-stop shop to go say, OK, I can see all of this software on all of these different machines And I can kind of bubble up the ones that are maybe out of date or whatever, so I can actually then action these types of things, right? And so the central management aspect has that, and it also has a bit of deployment in it If you need to do phased deployment, scheduled deployments, all that stuff, that’s all going to be wrapped into this central management website, services, and all that It’s kind of funny, because we have the agent service All right, so Chocolatey itself is just a CLI, right? It only runs when you call it But then we have the Chocolatey agent, and that is on each box, it’s running all the time, and it’s going to be doing that reporting back and forth And the master services — we didn’t want to call them Chocolatey masters, and so right now we’re thinking – You should call them Willy Wonkas – We’re thinking of calling them master chocolatiers, right? – Chocolatiers, I like that – You add all those in, and that’s how you scale, right? Because then all that brings all that information into one place and works back and forth with all of the different clients Right, so at current point, the performance is about 10,000 different clients can check into one of those master chocolatiers So that’s what’s coming – So it’s coming, being worked on – We’ve been working on it for a while We were really bad at estimating Software, right? You’re always pretty bad at estimating – Yeah – We just want to make sure it’s good to go and it’s really performant when it comes out that first time And so we’ve started to get it wrapped up so that we can actually get a limited beta out to some select customers so they can actually take a look at it, make sure that we’re addressing some of the big issues, and then start to give us really good feedback, so then we can start making it better – That sounds good – So that’s what that is – Awesome OK, Alan is asking, can Boxstarter change machine name, join domain, set up firewall rules, et cetera? – Boxstarter can do basically anything that you can do in PowerShell And really, Chocolatey essentially does the same thing – Does the same thing, yeah – It does the same thing Yeah, I mean,just to be clear, Boxstarter is a Chocolatey script It just wraps it up So one thing that, for example — let’s take domain joining as an example – Which would be a reboot situation – Exactly Right, so one of the tricky things about domain joining is you have to reboot I’m sure with the next version of Windows they’ll fix that, and you won’t have to reboot it anymore Really looking forward to that, thanks But so the trick is, like I said, anything you can do in PowerShell, you can do in Chocolatey You just have to write your PowerShell accordingly Basically, you have to say, am I domain joined? No, I’m not Go ahead and join me to the domain And what you can do is you can call — Boxstarter exposes a command where you can restart your computer You would do that instead of actually running the restart-computer command – I see – Because if you do that, then Boxstarter doesn’t know that you’re restarting the command, and it won’t actually – Using your API, let’s call it, basically now Boxstarter becomes in control of the Chocolatey flow and those type of things – Right, right For example, it’ll log you back on And so you might have a whole bunch of other stuff that has to happen after you join the domain Like, you might not be able to have access to your network shares until you join the domain, so that might have to go up at the very top of your script But as long as you have a guard around that script saying, “Am I domain joined? Yes, I am domain joined,” it’ll skip that, and it won’t do that reboot It’ll just go on – Yeah, that sounds great

Rob, you mentioned briefly — you said soon Chocolatey and Boxstarter are going to be the same thing Help us understand what’s on the horizon here – What’s on the horizon, OK You know, a while back we started talking about bringing Boxstarter under Chocolatey; talked with Matt to kind of continue that development, continue making sure that it stays as awesome as what Matt has brought to us and brought to the community And so we brought it under I think we’ve now brought in a little bit more security, starting to add in all those things that — a company that can handle that would take over And so Chocolatey Software is now taking over Boxstarter, and we’re starting to put more into it just to make sure that all that stuff is signed, everything is good, so that people can actually — you know, corporate environments especially — put a little bit more trust in that stuff – That’s great It’s good to see the marriage of the two worlds kind of being more tightly integrated and that type of thing, so that’s fantastic – I’m getting old, Tim You know, I can’t do this at two o’clock in the morning anymore – Yeah – Those were some good days, but yeah – The benefit is both of these are open source projects, is that correct? – Right, these are open source Boxstarter will stay open source I don’t believe in taking something away from the community, so that’s going to continue to be open source – And are you seeing a lot of community contributions to the core itself, or is it more about scripts? – We see a lot of community contributions in the way of packages on the community repository We have moderators They typically help out, and that’s all volunteer, for the most part And that’s where we see a lot of the contribution, because there’s a lot of software and neat tools out on Windows When I started all of this, I thought it’ll be great if we have this nice place that people can go and discover things Like, I don’t want Adobe Reader, or maybe I do But maybe there’s other options out there, and if I went somewhere and searched, right? Is there a place I could go and not have to worry about ads or any of this other stuff that’s trying to get me to other things I can just say, get to the core of this Find something that’s useful, and then use that, right? And so that’s one of the things, because like Matt and other developers, we don’t sit down and have a stock machine, right? We see all kinds of fun stuff on it – Right – Yeah, so that’s kind of that aspect – Awesome We have about two minutes left Yosef, you mentioned – Yeah – So we got the GitHub project, and we got a repository of some of the Windows dev setup script, categorized of like, hey, machine learning Here’s a set of things – That’s right This is a start – It’s a start – So what are you looking for? – I’m excited about, one, more scripts Like, seeing that list grow And then, really diving into what else we want to do with these A couple examples is we’ve just enabled so you can do a command line install of a distro for WSL And so you saw in the sample script that you can turn on the Windows Subsystem for Linux optional feature, but we also are enabling install of the distro – The next step of that, right? – The next step of that Well, the next step after that is I want to go in and install tools in that WSL distro, so let’s work that out And so we have this collaboration, and we can go figure this out You know, I’m optimistic And then there’s a bunch of other things I’d love the community to come in and say, “We want it to do this; we want it to do that,” and then we iron out who can make those contributions, whether it’s teams on the particular tools or whatever So that’s what’s exciting – All of the community, contribute more scripts – That’s right – Tell us what you need on both sides, right? – Oh, yeah, absolutely – With the remaining time we have, real quickly, what is If people are just now hearing this, they’re excited, where do they go to get more information? How do they get started? – Well, so there’s the Microsoft repository, but you can start at chocolatey.org That’ll get you there – Yep, chocolatey.org – Boxstarter.org, that’s another place – Awesome – And then the GitHub repo has a short URL, which is aka.ms/devsetup – Aka.ms/devsetup Actually, that has links to Chocolatey and Boxstarter as well – Yeah, for sure – Well, great Well, thank you guys for joining us here at Build It was great to see the recognition in the keynote Very, very useful tool for developers Hopefully, we can get some more contributions for a bunch of different, unique scenarios and things like that And then, congratulations for a lot of this hard work It’s a very helpful tool for developers on Windows, so appreciate it Thanks for coming – Awesome – Thanks – Thank you – And we will have more here at Build coming up Stay tuned for more on Channel 9 Live Coming up next is the IoT Show with Olivier and crew here from Build Thank you