Get POSHOriginConfig

Brandon Olin edited this page Dec 12, 2015 · 7 revisions

Reads and processes a POSHOrigin configuration file and returns the result as one or more PowerShell custom objects containing the required options that when passed to a POSHOrigin DSC resource can provision the infrastructure the DSC resource represents.

Parameters

Name Type Required Description
Path string[] True The relative or absolute path(s) of the configuration files or folders to be processed
Recurse switch False Recursively process subfolders and files
Verbose switch False Enables verbose output

Aliases

gpoc

Examples

Read the configuration contained in vm_config.ps1 into a variable.

$config = Get-POSHOriginConfig -Path '.\vm_config.ps1' -Verbose

Read all the configurations in folder MyConfigs into a variable.

$configs = '.\MyConfigs' | Get-POSHOriginConfig -Verbose

Read the configurations my_vm.ps1 and my_vips into a variable.

$configs = '.\my_vm.ps1', 'my_vips.ps1' | Get-POSHOriginConfig -Verbose

Recursively read the configurations contained in the folder my_configs.

$configs = '.\MyConfigs' | Get-POSHOriginConfig -Recurse -Verbose
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.
Press h to open a hovercard with more details.