PowerShellRepositories registers and configures PowerShell module repositories.
When to use 'PowerShellRepositories'
Use this resource when you need to register internal or custom PowerShell repositories (e.g., a private NuGet feed or Azure Artifacts) as trusted sources for installing PowerShell modules. This is essential in enterprise environments that host internal modules or need to proxy the PowerShell Gallery.
Source |
|
DSC Resource |
|
Documentation |
| Parameter | Attribute | DataType | Description | Allowed Values |
|---|---|---|---|---|
Hashtable[] |
set of Powershell repositories |
| Parameter | Attribute | DataType | Description | Allowed Values |
|---|---|---|---|---|
Name |
Key |
String |
||
SourceLocation |
String |
|||
ScriptSourceLocation |
String |
|||
PublishLocation |
String |
|||
ScriptPublishLocation |
String |
|||
InstallationPolicy |
String |
|
||
PackageManagementProvider |
String |
|||
Ensure |
String |
|
Example
PowerShellRepositories:
Repositories:
- Name: RepoA
SourceLocation: https://somegallery/v2
PublishLocation: https://somegallery/v2
- Name: RepoB
InstallationPolicy: trusted
SourceLocation: https://somegallery/v2