About
PowerShell module for automating MDT (Microsoft Deployment Toolkit) deployments with OSDCloud support.
Author
David Segura
Company
Recast Software
License
See LICENSE
PS Editions
Core (7+), Desktop (5.1)
Min PS Version
5.1
Requirements
PowerShell 7+ — required for
Enable-OSDeployMDTandBuild-OSDeployMDTWindows PowerShell 5.1 — loads MDT cmdlet helpers only; no public functions exported
Windows ADK installed (for
Build-OSDeployMDTWinPE customization)MDT installed (for MDT cmdlet support in PS5.1)
Installation
From the PowerShell Gallery (future)
Install-Module -Name OSDeployMDTFrom Source
Functions
Enable-OSDeployMDT
Enable-OSDeployMDTOne-time initialization of an MDT Deployment Share for OSDCloud integration. Run this once after creating a new deployment share, before the first Update Deployment Share.
Creates
Templates\,Templates\winpe-driver\, andTemplates\winpe-extrafiles\foldersCopies
LiteTouchPE.xml,winpeshl.ini,wimscript.ini,Unattend_PE_x64.xmlfromINSTALLDIR\TemplatesCopies
Background.bmpwallpaper fromINSTALLDIR\Samples(replaceable)Rewrites
%INSTALLDIR%path references inLiteTouchPE.xmlto%DEPLOYROOT%Syncs WinPE
<Components>fromBoot\LiteTouchPE_x64.xml(or writes a default set)Registers
Build-OSDeployMDTas a LiteTouchPE exit so it runs on every Update Deployment ShareUpdates
Control\Settings.xml: disables x86 boot image, sets scratch space to 512 MB, sets paths
Requires Administrator rights. See docs/Enable-OSDeployMDT.md for full details.
Build-OSDeployMDT
Build-OSDeployMDTMDT LiteTouchPE exit script — runs automatically during Update Deployment Share. Requires PowerShell 7+.
WIM stage — customizes the mounted WinPE image:
Collects EFI boot files and ADK
oscdimgbinaries intoDEPLOYROOT\Boot\bootbins\Copies
oa3tool.exe(OEM Activation 3.0) into WinPESystem32Applies DISM locale and time-zone settings
Adds
PackageManagementandPowerShellGetmodules (enables PowerShell Gallery in WinPE)Adds
AzCopy,curl, and7-ZiptoSystem32Saves the
OSDCloudmodule into the WinPE imageInjects WinPE drivers from
DEPLOYROOT\Templates\winpe-driver\(automatic) and optionally from the OSDeployCore library (interactive picker)
POSTISO stage — builds a patched ISO with bootmgfw_EX.efi for UEFI CA 2023 Secure Boot compliance.
-SetAllIntl
String
IETF locale tag for all International settings. Default: en-us.
-SetInputLocale
String
Default keyboard input locale. Default: en-us.
-SetTimeZone
String
WinPE time zone name (validated against tzutil /l). Default: current system time zone.
See docs/Build-OSDeployMDT.md for full details.
Typical Workflow
Project Structure
Running Tests
Pester v5 is required.
Contributing
Fork the repository and create a feature branch.
Add or update the relevant function in
OSDeployMDT\Public\orOSDeployMDT\Private\.Add a corresponding
*.Tests.ps1file undertests\.Update
FunctionsToExportinOSDeployMDT.psd1for any new public functions.Bump
ModuleVersioninOSDeployMDT.psd1following Semantic Versioning.Add an entry to CHANGELOG.md.
Open a Pull Request.
Last updated
Was this helpful?

