Creating Boot Media
Boot Media is the bootable USB or ISO the device starts from. It carries a secure token that ties it to a specific customer (tenant).
Build steps
- Left navigation → Boot Media → New.
- Select the customer (tenant) the media is for. This matters, the device pulls that tenant's content and branding.
- Choose USB or ISO.
- Generate, then write it to a USB stick or burn the ISO.
Important
- The media is scoped to the tenant you selected. If you deploy a device from a USB built for the wrong customer, it will pull that customer's content and branding, always build media for the correct customer.
- Keep the boot media up to date when you change the standard image or agent.
- On sites with a Site Server running Network Boot, you can skip the USB entirely - devices boot CloudImage straight over the LAN.
Advanced: building the WinPE boot media
The steps above cover generating a boot-media token in the portal. This section covers actually building the bootable WinPE image as a USB, an ISO, or a WIM you import into WDS for PXE, with the CloudImage agent and your customer's token baked in. Do this once per customer on a Windows build machine.
Prerequisites
- Windows ADK (latest) with the Deployment Tools feature and the Windows PE add-on.
- The CloudImage agent files (
agent/folder: the.ps1scripts,startnet.cmd,cloudimage-agent.json.template). - A Boot Media token for the customer (portal → Boot Media → New).
- (Recommended) the vendor WinPE driver packs (NIC / storage) for the hardware you deploy.
Step 1. Create the WinPE working set
Open Deployment and Imaging Tools Environment as Administrator:
copype amd64 C:\WinPE\amd64Step 2. Mount the boot image
Dism /Mount-Image /ImageFile:"C:\WinPE\amd64\media\sources\boot.wim" /index:1 /MountDir:"C:\WinPE\mount"Step 3. Add the required optional components
The agent needs PowerShell, WMI, .NET, scripting, storage, and DISM cmdlets:
set OC=C:\Program Files (x86)\Windows Kits\10\Assessment and Deployment Kit\Windows Preinstallation Environment\amd64\WinPE_OCs
Dism /Add-Package /Image:"C:\WinPE\mount" /PackagePath:"%OC%\WinPE-WMI.cab"
Dism /Add-Package /Image:"C:\WinPE\mount" /PackagePath:"%OC%\en-us\WinPE-WMI_en-us.cab"
Dism /Add-Package /Image:"C:\WinPE\mount" /PackagePath:"%OC%\WinPE-NetFx.cab"
Dism /Add-Package /Image:"C:\WinPE\mount" /PackagePath:"%OC%\en-us\WinPE-NetFx_en-us.cab"
Dism /Add-Package /Image:"C:\WinPE\mount" /PackagePath:"%OC%\WinPE-Scripting.cab"
Dism /Add-Package /Image:"C:\WinPE\mount" /PackagePath:"%OC%\WinPE-PowerShell.cab"
Dism /Add-Package /Image:"C:\WinPE\mount" /PackagePath:"%OC%\en-us\WinPE-PowerShell_en-us.cab"
Dism /Add-Package /Image:"C:\WinPE\mount" /PackagePath:"%OC%\WinPE-StorageWMI.cab"
Dism /Add-Package /Image:"C:\WinPE\mount" /PackagePath:"%OC%\WinPE-DismCmdlets.cab"
Dism /Add-Package /Image:"C:\WinPE\mount" /PackagePath:"%OC%\en-us\WinPE-DismCmdlets_en-us.cab"Step 4. (Recommended) inject WinPE NIC / storage drivers
Modern laptops often boot WinPE with no network or no visible disk, which stops the deploy before it starts. Inject the vendor WinPE driver pack (boot-critical NIC / storage only, not the full OS driver pack) as extracted .inf folders:
Dism /Image:"C:\WinPE\mount" /Add-Driver /Driver:"C:\Drivers\Dell-WinPE" /RecurseRepeat per vendor. Dell, HP, and Lenovo publish dedicated "WinPE driver packs" for exactly this.
Step 5. Copy in the agent and your customer's token
mkdir "C:\WinPE\mount\Windows\System32\CloudImage"
copy startnet.cmd "C:\WinPE\mount\Windows\System32\startnet.cmd"
copy *.ps1 "C:\WinPE\mount\Windows\System32\CloudImage\"
copy cloudimage-agent.json.template "C:\WinPE\mount\Windows\System32\CloudImage\cloudimage-agent.json"
:: optional, only if you still use legacy EXE driver packs; ZIP/CAB packs don't need it:
copy 7za.exe "C:\WinPE\mount\Windows\System32\CloudImage\"Then edit ...\Windows\System32\CloudImage\cloudimage-agent.json and paste your token:
{
"apiUrl": "https://app.cloudimage.co.uk",
"agentToken": "PASTE_YOUR_BOOT_MEDIA_TOKEN"
}- apiUrl: your CloudImage URL (default shown).
- agentToken: the token from the portal's Boot Media page. This scopes the media to that customer, the device pulls that customer's content and branding. Build separate media per customer.
You rarely rebuild the image. The agent .ps1 scripts self-update from the server on every boot, so agent fixes ship automatically. Only rebuild when the token / customer, the WinPE drivers or components, or 7za.exe change.
Step 6. Unmount and commit
Dism /Unmount-Image /MountDir:"C:\WinPE\mount" /CommitC:\WinPE\amd64\media\sources\boot.wim is now your finished CloudImage WinPE image.
Step 7. Produce the media (choose one)
USB stick (E: is the USB drive):
MakeWinPEMedia /UFD C:\WinPE\amd64 E:ISO (VMs, burning, or remote KVM):
MakeWinPEMedia /ISO C:\WinPE\amd64 C:\WinPE\CloudImage-WinPE.isoWDS / PXE (network boot): you don't need MakeWinPEMedia, import the committed boot.wim directly as a WDS boot image:
- WDS console: your server → Boot Images → Add Boot Image, select
C:\WinPE\amd64\media\sources\boot.wim. - PowerShell:
Import-WdsBootImage -Path "C:\WinPE\amd64\media\sources\boot.wim"
Devices that PXE-boot from WDS then load CloudImage WinPE straight off the network, no USB required.