Hello,
We are trying to install Windows 10 ADK under user context. We performed following steps:
-
Created self signed certificate for Target Node and Authoring Node on Target Node(referred https://msdn.microsoft.com/en-us/powershell/dsc/secureMOF)
-
Ran following script to install ADK, but ADK keeps on installing under system context when checked in task manager on target node.
I checked the mof file created and it shows credential=NULL.
Please guide of we are missing on anything.
Configuration MyConfiguration
{
param(
[Parameter(Mandatory)]
[PSCredential]$MyCredential
)
Import-DscResource -ModuleName PSDesiredStateConfiguration
Node $AllNodes.NodeName
{
Script ADK10
{
SetScript = {& \\UNCPATH\ADK10.cmd}
TestScript = {$False}
GetScript = {# Do Nothing}
}
Credential = $credential
}
LocalConfigurationManager
{
CertificateID = '3F6609C3FB9E8BC141F04C9EB07186E346DD64AA'
}
}
}
$cd = @{
AllNodes = @(
@{
NodeName = “TargetServerName”
PSDscAllowDomainUser = $true
CertificateFile = ‘Path to public key certificate’
Thumbprint = ‘3F6609C3FB9E8BC141F04C9EB07186E346DD64AA’
}
)
}
MyConfiguration -ConfigurationData $Cd -OutputPath “\UNCPath\Test3”
Set-DscLocalConfigurationManager -Path “\UNCPath\Test3” -Force -Verbose
Start-DscConfiguration -Path “\UNCPath\Test3” -Wait -Verbose -force