Source
The Source
DSC resource is used to configure AnyPackage package sources.
Syntax
Source [String] #ResourceName
{
Location = [string]
Name = [string]
Provider = [string]
[AdditionalParameters = [HashTable]]
[Ensure = [string]{ Absent | Present }]
[Trusted = [bool]]
}
Properties
AdditionalParameters
Specifies provider dynamic parameters.
Attribute: Write
Type: HashTable
Default value: None
Ensure
Specifies if the package source should be present.
Attribute: Write
Type: bool
Default value: Present
Location
Specifies the package source location.
Attribute: Required
Type: string
Default value: None
Name
Specifies the package source name.
Attribute: Key
Type: string
Default value: None
Provider
Specifies the package provider full name. The provider full name is in the following format: ModuleName\ProviderName. For AnyPackage PSResourceGet provider it would be: AnyPackage.PSResourceGet\PSResourceGet.
Attribute: Key
Type: string
Default value: None
Reasons
Returns reasons why the resource is not in compliance. The Code
property is the unique identifier and Phrase
property is the human readable reason.
Attribute: Read
Type: string
Default value: N/A
Trusted
Specifies if the package source is trusted. If set to true
it prevents interactive untrusted source prompts.
Attribute: Write
Type: string
Default value: False