< Back

Out-Config

Mon Jan 13, 2020 12:36 am

NAME Out-Config



SYNOPSIS

Generates a configuration from any input object





SYNTAX

Out-Config -InputObject <PSObject[]> [[-Name] <String>] [<CommonParameters>]





DESCRIPTION

Generates a PowerShell DSC configuration based off of a series of input objects or hashtables.



The properties Node, ResourceName, and SetttingName are used to define their corresponding parts in a DSC

configuration.





PARAMETERS

-InputObject <PSObject[]>



Required? true

Position? named

Default value

Accept pipeline input? true (ByValue)

Accept wildcard characters? false



-Name <String>

The name of the new configuration. If this is not provided, the name 'NewConfiguration' will be used.



Required? false

Position? 2

Default value

Accept pipeline input? false

Accept wildcard characters? false



<CommonParameters>

This cmdlet supports the common parameters: Verbose, Debug,

ErrorAction, ErrorVariable, WarningAction, WarningVariable,

OutBuffer, PipelineVariable, and OutVariable. For more information, see

about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).



INPUTS



OUTPUTS



-------------------------- EXAMPLE 1 --------------------------



PS C:\\>@{



ResourceName = 'WindowsFeature'

SettingName = 'IIS'

Ensure = 'Present'

Name = 'Web-Server'

}, @{

ResourceName = 'Package'

SettingName = 'UrlRewrite'

Ensure = "Present"

Name = "IIS URL Rewrite Module 2"

Path =

"http://download.microsoft.com/download/ ... tw_x64.msi"

Arguments = "/quiet"

ProductId = "EB675D0A-2C95-405B-BEE8-B42A65D23E11"

} |

Out-Config -Name IISInstall











RELATED LINKS

Split-Config

Join-Config