Tag Archives: Desired State Configuration

Script Block properties in DSC resources

Here’s a little-known feature of Desired State Configuration. First, notice that the Script resource’s properties are all strings, not ScriptBlocks, in its schema: However, even though they’re strings in the MOF file, PowerShell will allow you to assign ScriptBlock objects … Continue reading

Posted in PowerShell | Tagged | Leave a comment

Manage Local Group Policy Objects from PowerShell and Desired State Configuration

Ever since DSC was first released, people have been asking how they can use it to manage user-specific settings. For the most part, the answer has been: don’t do that. DSC resources execute as LocalSystem, and are intended to manage … Continue reading

Posted in PowerShell | Tagged , | 14 Comments

Automatic variables in Desired State Configuration

When you read through the DSC documentation at http://go.microsoft.com/fwlink/?LinkId=311940 , you learn that there are three automatic variables available to your DSC configuration code: $ConfigurationData , $AllNodes, and $Node. There are actually six automatic DSC variables. Not documented (and arguably … Continue reading

Posted in PowerShell | Tagged | 2 Comments