Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

windows: autounattend: add PnpCustomizationsWinPE component #18

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 25 additions & 1 deletion windows/autounattend.xml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,19 @@
<UILanguageFallback>en-US</UILanguageFallback>
<UserLocale>en-US</UserLocale>
</component>
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<!-- This component is responsible for insstalling custom drivers on the
final Windows image. The driver should be imported into install.wim
image below is an example with a path to a driver. The path must be
preceded with X drive latter. -->
<!--
<component name="Microsoft-Windows-PnpCustomizationsWinPE" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<DriverPaths>
<PathAndCredentials wcm:action="add">
<Path>X:\Windows\System32\DriverStore\FileRepository\e2fn.inf_amd64_fcb868ac03f43b71</Path>
</PathAndCredentials>
</DriverPaths>
</component>
--> <component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<DiskConfiguration>
<Disk wcm:action="add">
<CreatePartitions>
Expand Down Expand Up @@ -198,6 +210,18 @@
<Description>Installs Windows Updates</Description>
<CommandLine>powershell.exe -ExecutionPolicy Bypass Install-PackageProvider NuGet -Force; Register-PSRepository -Default -Verbose; Set-PSRepository -Name PSGallery -InstallationPolicy Trusted; Install-Module PSWindowsUpdate; Get-WindowsUpdate -AcceptAll -Install -AutoReboot;</CommandLine>
</SynchronousCommand>
<SynchronousCommand wcm:action="add">
<RequiresUserInput>false</RequiresUserInput>
<Order>8</Order>
<Description>Removes execution restrictions for current user</Description>
<CommandLine>powershell.exe -ExecutionPolicy Bypass Set-ExecutionPolicy -ExecutionPolicy Unrestricted -Scope CurrentUser</CommandLine>
</SynchronousCommand>
<SynchronousCommand wcm:action="add">
<RequiresUserInput>false</RequiresUserInput>
<Order>9</Order>
<Description>Removes execution restrictions for local machine</Description>
<CommandLine>powershell.exe -ExecutionPolicy Bypass Set-ExecutionPolicy -ExecutionPolicy Unrestricted -Scope LocalMachine</CommandLine>
</SynchronousCommand>
</FirstLogonCommands>
</component>
</settings>
Expand Down