Skip to content
OSDeploy PSModule and site pages are currently in preview until mid-September
For the complete documentation index, see llms.txt. This page is also available as Markdown.

WinpeStartup Core: Modify the WinPE Registry with a .reg File

Apply WinPE registry settings from a .reg file in the shared WinpeStartup Core main folder.

Add a .reg file to the shared WinpeStartup Core main folder to apply registry settings when WinPE starts.

Apply Registry Settings

1

Create the main Folder

Create the shared folder on the OSDeploy build computer:

$MainDirectory = Join-Path $env:ProgramData 'OSDeployCore\boot-assets\winpestartup-core\main'
New-Item -Path $MainDirectory -ItemType Directory -Force | Out-Null
2

Add a .reg File

Create a standard Windows Registry Editor .reg file. This example adds a value under HKLM\SOFTWARE\Contoso\WinPE:

@'
Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SOFTWARE\Contoso\WinPE]
"BuildTag"="BranchOffice"
'@ | Set-Content -LiteralPath (Join-Path $MainDirectory 'Contoso.reg') -Encoding utf8

Replace the example key and value with the settings required by your WinPE workflow.

3

Build WinPE Media

Run the build command. OSDeploy includes the shared main folder automatically when it is present:

Build-OSDeployBoot

Boot the resulting media to apply the registry settings.

Last updated

Was this helpful?