Needed:
- Vanilla Win 10 ISO https://www.microsoft.com/en-us/software-download/windows10
- https://docs.microsoft.com/en-us/windows-hardware/get-started/adk-install
- https://www.ntlite.com/download/
Basic Process:
- Wim Witch
- Slipstream Windows updates
- Inject .Net
- Update OneDrive client
- Start Menu Layout
- Windows Default Apps Removal
- Driver Integration
- Removes unnecessary Windows editions (home, education, etc)
- Creates a new ISO with the above
- NTLite
- NO UNATTENDED SETTINGS
- Configure settings for Windows
- Removes pre-installed OEM apps
- Image Builder PowerShell script
- Retrieves and injects Autopilot configuration
- Builds final ISO
- Creates final USB drive
Full Process:
Pre-Requisites:
- Download the vanilla Windows 10 ISO, link above.
- Download and install the ADK, link above.
- Download and install NTLite, link above.
- Set the start menu with the tiles you want to appear for new computer installations.
- Run from an elevated PowerShell to export the start menu configuration:
- Export-StartLayout -UseDesktopApplicationID -Path C:\Temp\StartLayout.xml
- Run from an elevated PowerShell to install PowerShell 7:
- Invoke-Expression “& { $(Invoke-RestMethod -Method Get -Uri “https://aka.ms/install-powershell.ps1“) } -UseMSI”
- From an elevated PowerShell 7, install these modules:
- Install-Module WindowsAutoPilotIntune -Scope CurrentUser –Force
- Install-Module Microsoft.Graph.Intune -Scope CurrentUser –Force
- Install-Module Intune.USB.Creator -Scope CurrentUser -Force
Wim WItch:
- Install Wim Witch from PowerShell:
- Save-Script -Name WIMWitch -Path C:\Temp\WimWitch (change the path as necessary)
- Then run the downloaded wimwitch.ps1 in PowerShell, C:\Temp\Wimwitch\WIMWitch.ps1
- Running that script for the first time will create a bunch of folders in the location the wimwitch.ps1 is run from.
- After the script is finished running, manually create a New Folder in that same location named CompletedISOs
- If this is the first time running Wim Witch, go into the tab Update Catalog. Otherwise, go to Step 4
- Select OSDSUS from the dropdown
- Click the Install/Update button.
- Wait until you see “Please close WIM Witch and all PowerShell windows, then rerun to continue…” and then close the Wim Witch window and PowerShell.
- Reopen PowerShell and run the WimWitch.ps1 script again.
- Select the vanilla windows 10 ISO
- Choose to import install.wim, .NET binaries, and ISO/Upgrade Package Files
- Give a name to the new wim. don’t put the .wim at the end
- Go into Source WIM and select the new wim just imported
- Go into Update Catalog, check the Windows edition needed as well as Optional and Dynamic Updates, and click Download
- Go into Customizations, check Inject .NET 3.5, Update OneDrive Client, and Enable Updates
- Go into Other Custom, and Enable Start Menu Layout. Select the StartLayout.xml file created in Step 3.
- Go into App Removal and select the applications to remove.
Microsoft.BingWeather_4.25.20211.0_neutral_~_8wekyb3d8bbwe
Microsoft.Getstarted_8.2.22942.0_neutral_~_8wekyb3d8bbwe
Microsoft.Microsoft3DViewer_6.1908.2042.0_neutral_~_8wekyb3d8bbwe
Microsoft.MicrosoftOfficeHub_18.1903.1152.0_neutral_~_8wekyb3d8bbwe
Microsoft.MicrosoftSolitaireCollection_4.4.8204.0_neutral_~_8wekyb3d8bbwe
Microsoft.MicrosoftStickyNotes_3.6.73.0_neutral_~_8wekyb3d8bbwe
Microsoft.MixedReality.Portal_2000.19081.1301.0_neutral_~_8wekyb3d8bbwe
Microsoft.Office.OneNote_16001.12026.20112.0_neutral_~_8wekyb3d8bbwe
Microsoft.People_2019.305.632.0_neutral_~_8wekyb3d8bbwe
Microsoft.ScreenSketch_2019.904.1644.0_neutral_~_8wekyb3d8bbwe
Microsoft.SkypeApp_14.53.77.0_neutral_~_kzf8qxf38zg5c
Microsoft.Wallet_2.4.18324.0_neutral_~_8wekyb3d8bbwe
Microsoft.Windows.Photos_2019.19071.12548.0_neutral_~_8wekyb3d8bbwe
Microsoft.windowscommunicationsapps_16005.11629.20316.0_neutral_~_8wekyb3d8bbwe
Microsoft.Xbox.TCUI_1.23.28002.0_neutral_~_8wekyb3d8bbwe
Microsoft.XboxApp_48.49.31001.0_neutral_~_8wekyb3d8bbwe
Microsoft.XboxGameOverlay_1.46.11001.0_neutral_~_8wekyb3d8bbwe
Microsoft.XboxGamingOverlay_2.34.28001.0_neutral_~_8wekyb3d8bbwe
Microsoft.XboxIdentityProvider_12.50.6001.0_neutral_~_8wekyb3d8bbwe
Microsoft.XboxSpeechToTextOverlay_1.17.29001.0_neutral_~_8wekyb3d8bbwe
Microsoft.ZuneMusic_2019.19071.19011.0_neutral_~_8wekyb3d8bbwe
Microsoft.ZuneVideo_2019.19071.19011.0_neutral_~_8wekyb3d8bbwe
- Go into Drivers and select any folders that have driver .inf files you want to integrate.
- For Dell Latitude models, download packs here: https://www.dell.com/support/kbdoc/en-us/000109893/dell-command-deploy-driver-packs-for-latitude-models
- Go into Make it So:
- Give the final wim file a name, for example WimWitch-21H2 and have it save it into the Wim Witch subfolder CompletedWIMs
- Check Create ISO and give it a name, using the same name as the wim. Save it in the folder CompletedISOs
- Check Apply Dynamic Update
- Click the button Make It So!
Wim Witch takes about 50 minutes to run. Integrating drivers adds about 30 minutes.
NTLite:
NTLite is only necessary if you want to make further customizations to the image before the final build. If there are none, go straight to the next section.
- Using the new ISO in the CompletedISOs folder, extract the contents into a folder.
- In NTLite, click Add and point it to the folder you extracted the ISO to.
- Highlight the Windows version it shows and then press the button Load.
- This will mount the install.wim file found in the Windows folder so it can be customized.
- Make any further customizations if necessary.
- NO UNATTENDED SETTINGS SHOULD BE MADE HERE. I have found it will fail if any are made in NTLite
- Go to the Apply tab
- Under Options, check the box “Create ISO”, give it a name and save location.
- Click the Process button to finish and create the new ISO.
NTLite takes about 5 minutes to run.
Image Builder PowerShell script
- Plug in the USB flash drive that will be wiped and installed with the new image.
- In PowerShell 7 (this must be in PowerShell 7, not standard PowerShell ISE), run this command:
- Publish-ImageToUSB -winPEPath “https://githublfs.blob.core.windows.net/storage/WinPE.zip” -windowsIsoPath “C:\Path\To\NTLite_ISO_File.iso” -getAutopilotCfg
- EXAMPLE: Publish-ImageToUSB -winPEPath “https://githublfs.blob.core.windows.net/storage/WinPE.zip” -windowsIsoPath “C:\Temp\NTLite\NTLite.iso” -getAutopilotCfg
- NOTE – If you skipped the NTLite section, you would be using the ISO made from Wim Witch
- If this is the first time running the command, it will automatically download and extract the Windows PE to C:\Users\<Username>\AppData\Local\Temp\Win10. If you have run this already, it will detect the presence of PE and not download it again.
- You will then be asked to select the Windows image you want to use from the install.wim file. At this point, there should only be one image as Wim Witch would have stripped all others away (Wim Witch, step 5).
- If this is the first time running the command, you will then be asked to log in to your Azure tenant so it can grab the Autopilot configuration profile, using the standard Microsoft sign-in box.
- It will then ask for you to select the USB device. Once you select it, it will begin the process of deleting all partitions and data from the USB flash drive. It will then write the final image with the Autopilot configuration.
- Once it is finished, remote the USB flash drive and it is ready to be used to install Windows on a target device
Image Builder takes about 10 minutes.
Clean Up
- Once you are done, you can delete files you no longer need.
- First, save all configuration files from Wim Witch and NTLite
- Wim Witch config file is in Wimwitch\Config
- First, save all configuration files from Wim Witch and NTLite