C ONFIGURATION M ANAGEMENT ON W INDOWS S ERVER Desired State Configuration
D ECLARATIVE C ONFIGURATION M ANAGEMENT Provisioning Verification Iterative Development
D ESIRED S TATE C ONFIGURATION Platform Feature – Not a product API over Open Standards So why do you need to know this stuff? DSC can run standalone Be able to build composite configurations Be able to build custom resources
D ESIRED S TATE C ONFIGURATION Local Configuration Manager Configurations Resources
L OCAL C ONFIGURATION M ANAGER AllowModuleOverwrite CertificateID ConfigurationID ConfigurationMode ConfigurationModeFrequencyMins Credential DownloadManagerCustomData DownloadManagerName RebootNodeIfNeeded RefreshFrequencyMins RefreshMode
C ONFIGURATIONS Declarative-ish New keywords – configuration and node Dynamic keywords (from resources) Plus all the richness of PowerShell when you need it
L AB DETAILS User – localhost\administrator Password – Cascadia! Wireless network – DoinDSC Wireless password – Cascadia2014 Available machines
C ONFIGURATIONS Configuration MyLocalConfig { Node localhost { File SomeConfigFile {…} }
C ONFIGURATIONS Separate your environment from your data How? With ConfigurationData
C OMPOSITE C ONFIGURATIONS Configurations can use other configurations like resources. Configurations are just like functions... They can have parameters. Composite configurations are a way to logically group resources.
A PPLYING C ONFIGURATIONS Send-DscConfiguration
T ROUBLESHOOTING C ONFIGURATIONS cDscDiagnostics module
R ESOURCES WMI - based PowerShell - based
R ESOURCES WMI - Three methods GetTargetResource SetTargetResource TestTargetResource
R ESOURCES Powershell-based resources They reside in a module under a subfolder DscResources They are modules themselves with three functions Get-TargetResource Set-TargetResource Test-TargetResource
R ESOURCES Resources reside in modules on PSModulePath Defaults are $pshome/modules $env:programfiles/windowspowershell/modules
O THER S TUFF Pull Server SMB vs REST Workflow Source Control
D OCS AND R ESOURCES Github.com/powershellorg/ebooks Blogs.msdn.com/b/powershell Github.com/powershellorg/dsc Version Control By Example – ebook by Eric Sink