Organizing and using multiple files for configuration

I’m looking for some tips on organizing dsc configurations.
Instead of writting one giant configuration I would like to break them into smaller-individual scripts.

Such as writting individual configurations like:

Configuration WebServer {}
Configuration WindowsFeatures {}
Configuration Applications {}

My typical configuration is broken into 3 files:

The configuration:

Configuration SetupInstall
param (…)

Import-DSCResource -ModuleName xPSDesiredStateConfiguration

Node $AllNodes.where{ $_.Role.Contains("Production") }.NodeName
	# Resources added here...

SetupInstall -ConfigurationData “configData.psd1” -PackagePath “\…”

the config data:

AllNodes = @(
NodeName = “Example”
Role = “Production”
TempFolder = “c:\dsc”

The command to manually run the configuration until we use a pull server:

Start-DscConfiguration -Path .\SetupInstall -Verbose -Wait -Force

I would like to break the configurations into multiple files and still run one command to start the configuration.

If this is not clear imagine a scripting language like PHP:

// FileName: Config.php

What you’re describing is called a composite resource. With these, you can actually use DSC configurations as though they were resources. The configurations are given a param block (which defines what you can pass in when calling them from your outermost configuration), and they go under the DscResources folder structure of a module (in a file ending with .schema.psm1 ). See for more information.

I’ve created one simular to this for 7-zip which uses the set, test, and get-targetresource.They seem to have quite a bit of overhead for setting up. I may need to look into the deployment options for these resources to automate the installation of the modules from the repo to the server. I’ve seen some example with WMF 5 which uses classes to simplify some of this config.