Created
March 30, 2016 02:28
-
-
Save itpropro/7a24df5c2ec3d1aaa64ff21fd2500c17 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[DscLocalConfigurationManager()] | |
Configuration PullClientV2 { | |
param( | |
[Parameter(Mandatory=$True)] | |
[String]$ConfigurationNames, | |
[Parameter(Mandatory=$True)] | |
[String]$Server | |
) | |
Settings | |
{ | |
AllowModuleOverwrite = $true; | |
RefreshMode = 'PULL'; | |
RebootNodeIfNeeded = $true; | |
RefreshFrequencyMins = 30; | |
ConfigurationModeFrequencyMins = 15; | |
ConfigurationMode = 'ApplyAndAutoCorrect'; | |
ActionAfterReboot = 'ContinueConfiguration' | |
CertificateID = '1234561234561234561234561234561234561234' # Change thumbprint | |
} | |
ConfigurationRepositoryWeb PPS001 | |
{ | |
ServerUrl = 'https://' + $Server + ':443/PSDSCPullServer.svc' | |
RegistrationKey = 'c5effe3b-133d-483e-801f-69d33af75659' # Change at will (new-guid) | |
ConfigurationNames = @($ConfigurationNames) | |
} | |
} | |
PullClientV2 -Server $PullServer -ConfigurationNames $ConfigurationID # Change on demand | |
$FilePath = (Get-Location -PSProvider FileSystem).Path + '\PullClientV2' | |
Set-DscLocalConfigurationManager -ComputerName 'Localhost' -Path $FilePath |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment