Levearging DSC for just a small number of servers is very straight forward and the push model is a solid method to deliver the configurations to the server. However when you have several systems you want to configure, leveraging the pull model is a great
- [Voiceover] So one of the great things about DSC configuration files that we've seen, is that they are fairly easy to apply. But when you use the Push Model, it seems like a very manual process and for the most part it is. We have to push the files to the actual server they're going to be on and then we actually have to apply those files. And if anything happens to the configuration on those systems, we have to re-apply those files and restore the DSC configuration. One of the great things we have with this DSC platform, is we have a Pull Model. And we can create what are called pull servers that allow us to have kinda of a central staging point for our DSC environment.
So, when we take a look at the three phases again. When we understand how they work. We have Authoring which is always going to be the first phase where we actually create these configuration files. It works the same way, right. You're gonna to author those configuration files in PowerShell, pretty much exactly the same way that you did for the Push Model. The difference comes is where we actually put those files to be processed. And that is what is known as a pull server. Now that pull server can be either just a simple file server with an SMB protocol for a file share or it can be a web server using HTTP or if you want to add some security, with HTTPS, as well.
And all that does is it provides a central location for our DSC configuration files and data and, possibly, any modules that we may need to process on those clients. The great thing about this is, with that central location, it really gives you a nice repository of where we can store all the files. It's all gonna be in that one location. And makes changes to an entire environment very quick to do. The other thing that will be different, is how the Configuration Phase works. What will happen now, is we'll actually reach into that server, on those local configurations, modify their Local Configuration Management client, the LCM client, to actually tell it to use the pull server.
When we set that up, we create a bi-directional relationship between where our Staging Phase is and the actual clients. In other words, the clients will regularly poll the pull server to make sure that we are getting the data and we're always up-to-date. So, if something does happen and we have that configuration drift or something gets deleted those servers are just going to make it sale by themselves. They're going to get back to that state that we desire automatically for you. So, when you think about the Pull Model, it really allows us to have that kinda dynamic and automated model for our DSC files.
Authoring still works the same way. We'll just now putting those files in a different location. And the clients on the other end are just, essentially, taking care of themselves. Now, when you create the pull servers, there actually are some requirements that you have to keep in mind to actually work with this. If you are going to make an SMB pull server, you have to have PowerShell 4.0 or higher for both the server and the client. Once again, with PowerShell 5.0 already out, I recommend that. You have to create an SMB share. Fairly, simple. Just create a file share.
You have to configure the client to pull from that SMB share. Now we'll actually see that in a couple of videos. We'll show you how to set up a server and then we'll show how to set up the client, as well. Now the nice thing about this, it's fairly easy to do. Now you can also do the same thing if you want to make a web server. The requirements are a little different but some of the same things. Although we do have to have PowerShell 5.0 or greater for this to work. So, we do need 5.0 for that web pull server inside of your environments. You, basically, need the IIS server role installed. Basically, a web server for us to process those HTTP requests.
You also need to install the DSC service. This is a service built-in to your Windows server platforms for us to install, as an additional feature on our servers. And, then lastly, you have to have a certificate to help negotiate those credentials passing to the target nodes. In other words, we want to have secure authentication back into our web server. In another video, I'll show you how to set that up, as well. So, there are some requirements about what you want to do. Now what's interesting is, Matt, which one would I pick? - [Voiceover] Well, I'll tell you from a server side. The SMB pull server is real easy to set up.
But from the LCM client side, there's a little more complexity involved in making sure that client can actually set that up and find those files. Whereas, the HTTP server requires a little more complexity to install and get it ready to go. It makes the client side configuration easier to use. At the end of the day, it's really up to you and what works for you and for your environment of which one you're going to see. And in the videos in this course, you're going to see how to do both. You're going to see how to configure the client side for both of them, as well.
Current IT pros will need to understand DSC as they move into managing Microsoft's next wave of server and cloud products that will leverage this important technology. In this course, Matt Hester shows how to write configuration documents, work with DSC resources, and apply configurations to systems via both push and pull modes. Plus, he shows how to troubleshoot DSC and use DSC in non-Windows environments like Linux.
- Why we need DSC
- Understanding DSC architecture
- Working with built-in and custom resources
- Creating a DSC configuration
- Staging configured data
- Creating, testing, and restoring DSC configurations with the push model
- Configuring pull servers
- Creating and testing DSC configurations with the pull model
- Using DSC in Linux environments
- Troubleshooting DSC