agent-dev-env 0.1.0-canary.2.fbbd044

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (102) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +106 -0
  3. package/dist/assets/bridge/bridge.js +202 -0
  4. package/dist/assets/guest/guest-agent-mac.js +586 -0
  5. package/dist/assets/guest/guest-agent-ubuntu.js +481 -0
  6. package/dist/assets/guest/guest-agent-windows.js +466 -0
  7. package/dist/assets/images/mac/CHANGELOG.md +265 -0
  8. package/dist/assets/images/mac/README.md +63 -0
  9. package/dist/assets/images/mac/sandbox.pkr.hcl +468 -0
  10. package/dist/assets/images/mac/vars/sandbox-macos-tahoe.pkrvars.hcl +39 -0
  11. package/dist/assets/images/ubuntu-arm64-vmware/CHANGELOG.md +239 -0
  12. package/dist/assets/images/ubuntu-arm64-vmware/README.md +177 -0
  13. package/dist/assets/images/ubuntu-arm64-vmware/autoinstall/meta-data +2 -0
  14. package/dist/assets/images/ubuntu-arm64-vmware/autoinstall/user-data +34 -0
  15. package/dist/assets/images/ubuntu-arm64-vmware/sandbox.pkr.hcl +776 -0
  16. package/dist/assets/images/ubuntu-arm64-vmware/vars/sandbox-ubuntu-24-04-arm64-vmware.pkrvars.hcl +71 -0
  17. package/dist/assets/images/windows-arm64-qemu/CHANGELOG.md +209 -0
  18. package/dist/assets/images/windows-arm64-qemu/README.md +142 -0
  19. package/dist/assets/images/windows-arm64-qemu/autounattend.xml +325 -0
  20. package/dist/assets/images/windows-arm64-qemu/qemu-with-tpm.sh +170 -0
  21. package/dist/assets/images/windows-arm64-qemu/sandbox.pkr.hcl +1012 -0
  22. package/dist/assets/images/windows-arm64-qemu/vars/sandbox-windows-11-arm64-qemu.pkrvars.hcl +83 -0
  23. package/dist/assets/images/windows-arm64-vmware/CHANGELOG.md +270 -0
  24. package/dist/assets/images/windows-arm64-vmware/README.md +171 -0
  25. package/dist/assets/images/windows-arm64-vmware/autounattend.xml +311 -0
  26. package/dist/assets/images/windows-arm64-vmware/sandbox.pkr.hcl +1036 -0
  27. package/dist/assets/images/windows-arm64-vmware/vars/sandbox-windows-11-arm64-vmware.pkrvars.hcl +83 -0
  28. package/dist/assets/rules/agent-rules-linux.md +68 -0
  29. package/dist/assets/rules/agent-rules.md +71 -0
  30. package/dist/assets/watchdog/watch-build-ocr.swift +40 -0
  31. package/dist/assets/watchdog/watch-build.py +275 -0
  32. package/dist/cli.js +52 -0
  33. package/dist/commands/delete.js +179 -0
  34. package/dist/commands/doctor.js +165 -0
  35. package/dist/commands/list.js +38 -0
  36. package/dist/commands/not-yet.js +15 -0
  37. package/dist/commands/register.js +150 -0
  38. package/dist/commands/run.js +65 -0
  39. package/dist/commands/status.js +142 -0
  40. package/dist/commands/stop.js +186 -0
  41. package/dist/commands/sync.js +98 -0
  42. package/dist/lib/exec.js +250 -0
  43. package/dist/lib/ghcr.js +82 -0
  44. package/dist/lib/git.js +100 -0
  45. package/dist/lib/logger.js +87 -0
  46. package/dist/lib/network.js +63 -0
  47. package/dist/lib/paths.js +116 -0
  48. package/dist/lib/platform.js +87 -0
  49. package/dist/lib/prompt.js +66 -0
  50. package/dist/lib/qemu.js +373 -0
  51. package/dist/lib/regex.js +9 -0
  52. package/dist/lib/ssh.js +230 -0
  53. package/dist/lib/tart.js +210 -0
  54. package/dist/lib/template.js +35 -0
  55. package/dist/lib/vars.js +99 -0
  56. package/dist/lib/vmrun.js +334 -0
  57. package/dist/lifecycle/build-macos.js +23 -0
  58. package/dist/lifecycle/build-qemu.js +204 -0
  59. package/dist/lifecycle/build-shared.js +355 -0
  60. package/dist/lifecycle/build-ubuntu.js +184 -0
  61. package/dist/lifecycle/build-watchdog.js +146 -0
  62. package/dist/lifecycle/build-windows-vmware.js +112 -0
  63. package/dist/lifecycle/build.js +55 -0
  64. package/dist/lifecycle/catalog.js +165 -0
  65. package/dist/lifecycle/deploy.js +161 -0
  66. package/dist/lifecycle/tag.js +77 -0
  67. package/dist/lifecycle/watch-build.js +64 -0
  68. package/dist/runners/bridges.js +156 -0
  69. package/dist/runners/framework.js +66 -0
  70. package/dist/runners/macos-bridges.js +143 -0
  71. package/dist/runners/macos-guest.js +76 -0
  72. package/dist/runners/macos-rules.js +77 -0
  73. package/dist/runners/macos-summary.js +145 -0
  74. package/dist/runners/macos.js +258 -0
  75. package/dist/runners/openchamber.js +60 -0
  76. package/dist/runners/options.js +56 -0
  77. package/dist/runners/qemu-image.js +183 -0
  78. package/dist/runners/rules.js +49 -0
  79. package/dist/runners/ubuntu-bridges.js +154 -0
  80. package/dist/runners/ubuntu-guest.js +136 -0
  81. package/dist/runners/ubuntu-image.js +26 -0
  82. package/dist/runners/ubuntu-rules.js +86 -0
  83. package/dist/runners/ubuntu-shared.js +65 -0
  84. package/dist/runners/ubuntu-summary.js +141 -0
  85. package/dist/runners/ubuntu.js +117 -0
  86. package/dist/runners/vmware-common.js +158 -0
  87. package/dist/runners/vmware-image.js +242 -0
  88. package/dist/runners/windows-autologon.js +119 -0
  89. package/dist/runners/windows-bridges.js +136 -0
  90. package/dist/runners/windows-guest.js +213 -0
  91. package/dist/runners/windows-image.js +23 -0
  92. package/dist/runners/windows-qemu-summary.js +85 -0
  93. package/dist/runners/windows-qemu.js +189 -0
  94. package/dist/runners/windows-shared.js +68 -0
  95. package/dist/runners/windows-summary.js +104 -0
  96. package/dist/runners/windows.js +96 -0
  97. package/dist/settings/common.js +107 -0
  98. package/dist/settings/macos-copy.js +223 -0
  99. package/dist/settings/macos.js +41 -0
  100. package/dist/settings/ubuntu-copy.js +223 -0
  101. package/dist/settings/ubuntu.js +68 -0
  102. package/package.json +52 -0
@@ -0,0 +1,311 @@
1
+ <?xml version="1.0" encoding="utf-8"?>
2
+ <!--
3
+ autounattend.xml — Windows 11 ARM64 unattended install for the Packer
4
+ VMware build (images/windows-arm64-vmware/sandbox.pkr.hcl).
5
+
6
+ Windows Setup probes attached removable media for Autounattend.xml at
7
+ the root and applies it before the language picker. The CD is built by
8
+ Packer's cd_files from this file + the vmxnet3 ARM64 driver staged by
9
+ the build flow (extracted from VMware Fusion's
10
+ Contents/Library/isoimages/arm64/drivers-arm64.zip, placed flat at the
11
+ CD root).
12
+
13
+ Unlike the QEMU image no WinPE driver is needed: the disk is NVMe (the
14
+ NVMe driver is in-box in Windows 11 ARM64) and Setup runs offline, so no
15
+ network, storage or input drivers are required in the windowsPE pass.
16
+ The vmxnet3 NIC driver, however, must be installed at first logon
17
+ BEFORE any network use — Windows 11 ARM64 has no in-box driver for
18
+ VMware NICs, so without it there is no network in the guest and WinRM
19
+ would be unreachable from the host (FirstLogonCommands order 1 scans
20
+ the unattend CD; drive letters on EFI installs are non-deterministic,
21
+ so D:..H: candidates are listed).
22
+
23
+ VMware Tools are installed at first logon (FirstLogonCommands order 2,
24
+ BEFORE WinRM) — the builder attaches Fusion's ARM64 tools ISO
25
+ (tools_mode "attach"), and moving the install after WinRM would break
26
+ it (the tools installer rebinds the NIC).
27
+
28
+ Schema components carry processorArchitecture="arm64". The
29
+ Administrator password must stay in sync with the winrm_password
30
+ variable in vars/sandbox-windows-11-arm64-vmware.pkrvars.hcl — change both
31
+ together.
32
+
33
+ References:
34
+ - https://learn.microsoft.com/en-us/windows-hardware/customize/desktop/unattend/
35
+ - Recipe verified end-to-end on Apple Silicon in gusztavvargadr/packer
36
+ (https://github.com/gusztavvargadr/packer, src/windows/boot/ +
37
+ samples/windows-11/25h2-professional-arm64, Unlicense).
38
+ -->
39
+ <unattend xmlns="urn:schemas-microsoft-com:unattend">
40
+
41
+ <settings pass="windowsPE">
42
+
43
+ <component name="Microsoft-Windows-International-Core-WinPE"
44
+ processorArchitecture="arm64"
45
+ publicKeyToken="31bf3856ad364e35"
46
+ language="neutral" versionScope="nonSxS"
47
+ xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State">
48
+ <SetupUILanguage>
49
+ <UILanguage>en-US</UILanguage>
50
+ </SetupUILanguage>
51
+ <InputLocale>en-US</InputLocale>
52
+ <SystemLocale>en-US</SystemLocale>
53
+ <UILanguage>en-US</UILanguage>
54
+ <UserLocale>en-US</UserLocale>
55
+ </component>
56
+
57
+ <component name="Microsoft-Windows-Setup"
58
+ processorArchitecture="arm64"
59
+ publicKeyToken="31bf3856ad364e35"
60
+ language="neutral" versionScope="nonSxS"
61
+ xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State">
62
+
63
+ <!-- Pure-UEFI layout for ARM64: ESP + MSR + Windows. -->
64
+ <DiskConfiguration>
65
+ <Disk wcm:action="add">
66
+ <DiskID>0</DiskID>
67
+ <WillWipeDisk>true</WillWipeDisk>
68
+ <CreatePartitions>
69
+ <CreatePartition wcm:action="add">
70
+ <Order>1</Order>
71
+ <Type>EFI</Type>
72
+ <Size>300</Size>
73
+ </CreatePartition>
74
+ <CreatePartition wcm:action="add">
75
+ <Order>2</Order>
76
+ <Type>MSR</Type>
77
+ <Size>16</Size>
78
+ </CreatePartition>
79
+ <CreatePartition wcm:action="add">
80
+ <Order>3</Order>
81
+ <Type>Primary</Type>
82
+ <Extend>true</Extend>
83
+ </CreatePartition>
84
+ </CreatePartitions>
85
+ <ModifyPartitions>
86
+ <ModifyPartition wcm:action="add">
87
+ <Order>1</Order>
88
+ <PartitionID>1</PartitionID>
89
+ <Format>FAT32</Format>
90
+ <Label>System</Label>
91
+ </ModifyPartition>
92
+ <ModifyPartition wcm:action="add">
93
+ <Order>2</Order>
94
+ <PartitionID>2</PartitionID>
95
+ </ModifyPartition>
96
+ <ModifyPartition wcm:action="add">
97
+ <Order>3</Order>
98
+ <PartitionID>3</PartitionID>
99
+ <Format>NTFS</Format>
100
+ <Label>Windows</Label>
101
+ <Letter>C</Letter>
102
+ </ModifyPartition>
103
+ </ModifyPartitions>
104
+ </Disk>
105
+ </DiskConfiguration>
106
+
107
+ <!-- Multi-edition ISO: pick Pro by image name. If the release uses
108
+ a different SKU label (e.g. "Windows 11 Pro for ARM"), the
109
+ install halts — check with `dism /Get-WimInfo` on the ISO. -->
110
+ <ImageInstall>
111
+ <OSImage>
112
+ <InstallTo>
113
+ <DiskID>0</DiskID>
114
+ <PartitionID>3</PartitionID>
115
+ </InstallTo>
116
+ <InstallFrom>
117
+ <MetaData wcm:action="add">
118
+ <Key>/IMAGE/NAME</Key>
119
+ <Value>Windows 11 Pro</Value>
120
+ </MetaData>
121
+ </InstallFrom>
122
+ </OSImage>
123
+ </ImageInstall>
124
+
125
+ <UserData>
126
+ <AcceptEula>true</AcceptEula>
127
+ <FullName>agent-dev-env</FullName>
128
+ <Organization>agent-dev-env</Organization>
129
+ <!-- Generic install key for Windows 11 Pro: lets Setup complete
130
+ without prompting; does NOT activate (the sandbox runs
131
+ unactivated with a watermark). -->
132
+ <ProductKey>
133
+ <Key>VK7JG-NPHTM-C97JM-9MPGT-3V66T</Key>
134
+ <WillShowUI>OnError</WillShowUI>
135
+ </ProductKey>
136
+ </UserData>
137
+
138
+ <!-- Bypass the Win11 hardware-requirements checks. Fusion provides
139
+ a virtual TPM 2.0 when one is configured, but Apple Silicon is
140
+ not on Microsoft's supported CPU list, so BypassCPUCheck is
141
+ mandatory; the rest are belt-and-braces. RunSynchronous in the
142
+ windowsPE pass runs strictly before Setup's hardware probe. -->
143
+ <RunSynchronous>
144
+ <RunSynchronousCommand wcm:action="add">
145
+ <Order>1</Order>
146
+ <Path>reg add HKLM\System\Setup\LabConfig /v BypassTPMCheck /t REG_DWORD /d 1 /f</Path>
147
+ </RunSynchronousCommand>
148
+ <RunSynchronousCommand wcm:action="add">
149
+ <Order>2</Order>
150
+ <Path>reg add HKLM\System\Setup\LabConfig /v BypassSecureBootCheck /t REG_DWORD /d 1 /f</Path>
151
+ </RunSynchronousCommand>
152
+ <RunSynchronousCommand wcm:action="add">
153
+ <Order>3</Order>
154
+ <Path>reg add HKLM\System\Setup\LabConfig /v BypassRAMCheck /t REG_DWORD /d 1 /f</Path>
155
+ </RunSynchronousCommand>
156
+ <RunSynchronousCommand wcm:action="add">
157
+ <Order>4</Order>
158
+ <Path>reg add HKLM\System\Setup\LabConfig /v BypassCPUCheck /t REG_DWORD /d 1 /f</Path>
159
+ </RunSynchronousCommand>
160
+ <RunSynchronousCommand wcm:action="add">
161
+ <Order>5</Order>
162
+ <Path>reg add HKLM\System\Setup\LabConfig /v BypassStorageCheck /t REG_DWORD /d 1 /f</Path>
163
+ </RunSynchronousCommand>
164
+ </RunSynchronous>
165
+ </component>
166
+ </settings>
167
+
168
+ <settings pass="specialize">
169
+ <component name="Microsoft-Windows-Shell-Setup"
170
+ processorArchitecture="arm64"
171
+ publicKeyToken="31bf3856ad364e35"
172
+ language="neutral" versionScope="nonSxS"
173
+ xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State">
174
+ <!-- NetBIOS computer names are limited to 15 chars — longer names
175
+ fail the specialize pass with hrResult=0x80220005. -->
176
+ <ComputerName>win11-sandbox</ComputerName>
177
+ <TimeZone>UTC</TimeZone>
178
+ <RegisteredOrganization>agent-dev-env</RegisteredOrganization>
179
+ <RegisteredOwner>agent-dev-env</RegisteredOwner>
180
+ </component>
181
+ <component name="Microsoft-Windows-International-Core"
182
+ processorArchitecture="arm64"
183
+ publicKeyToken="31bf3856ad364e35"
184
+ language="neutral" versionScope="nonSxS"
185
+ xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State">
186
+ <InputLocale>en-US</InputLocale>
187
+ <SystemLocale>en-US</SystemLocale>
188
+ <UILanguage>en-US</UILanguage>
189
+ <UserLocale>en-US</UserLocale>
190
+ </component>
191
+ </settings>
192
+
193
+ <settings pass="oobeSystem">
194
+ <component name="Microsoft-Windows-Shell-Setup"
195
+ processorArchitecture="arm64"
196
+ publicKeyToken="31bf3856ad364e35"
197
+ language="neutral" versionScope="nonSxS"
198
+ xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State">
199
+
200
+ <OOBE>
201
+ <HideEULAPage>true</HideEULAPage>
202
+ <HideLocalAccountScreen>true</HideLocalAccountScreen>
203
+ <HideOEMRegistrationScreen>true</HideOEMRegistrationScreen>
204
+ <!-- Bypasses the Microsoft-account requirement on Win11 24H2. If a
205
+ future release blocks this too, add BYPASSNRO registry writes
206
+ via RunSynchronous in the specialize pass. -->
207
+ <HideOnlineAccountScreens>true</HideOnlineAccountScreens>
208
+ <HideWirelessSetupInOOBE>true</HideWirelessSetupInOOBE>
209
+ <NetworkLocation>Work</NetworkLocation>
210
+ <ProtectYourPC>3</ProtectYourPC>
211
+ <SkipUserOOBE>true</SkipUserOOBE>
212
+ <SkipMachineOOBE>true</SkipMachineOOBE>
213
+ </OOBE>
214
+
215
+ <UserAccounts>
216
+ <AdministratorPassword>
217
+ <!-- MUST match winrm_password in the vars file. -->
218
+ <Value>sandbox1</Value>
219
+ <PlainText>true</PlainText>
220
+ </AdministratorPassword>
221
+ <LocalAccounts>
222
+ <LocalAccount wcm:action="add">
223
+ <Name>Administrator</Name>
224
+ <Group>Administrators</Group>
225
+ <Password>
226
+ <Value>sandbox1</Value>
227
+ <PlainText>true</PlainText>
228
+ </Password>
229
+ <Description>Local admin; also the SSH/RDP account of the sandbox.</Description>
230
+ <DisplayName>Administrator</DisplayName>
231
+ </LocalAccount>
232
+ </LocalAccounts>
233
+ </UserAccounts>
234
+
235
+ <!-- LogonCount=1: exactly one auto-login (the first OOBE boot, where
236
+ FirstLogonCommands brings up WinRM); Windows clears
237
+ AutoAdminLogon itself afterwards. -->
238
+ <AutoLogon>
239
+ <Username>Administrator</Username>
240
+ <Password>
241
+ <Value>sandbox1</Value>
242
+ <PlainText>true</PlainText>
243
+ </Password>
244
+ <Enabled>true</Enabled>
245
+ <LogonCount>1</LogonCount>
246
+ </AutoLogon>
247
+
248
+ <!-- Bring up WinRM so Packer's provisioners can connect.
249
+ Order is load-bearing:
250
+ 1. Install the vmxnet3 ARM64 NIC driver into the running OS's
251
+ driver store — Windows 11 ARM64 has no in-box VMware NIC
252
+ driver, so the (NAT) adapter is dead until pnputil
253
+ registers it. The driver lives flat at the root of the
254
+ unattend CD; drive letters differ per install, so scan
255
+ D:..H: candidates.
256
+ 2. Install VMware Tools from the attached tools CD (the
257
+ builder's tools_mode "attach") — *before* WinRM, because
258
+ the tools installer rebinds the NIC and drops every live
259
+ WinRM session mid-install (observed as a hard provisioner
260
+ failure). The tools are what make vmrun getGuestIPAddress
261
+ and HGFS shared folders work at runtime. The ARM64 tools
262
+ package ships no VMCI driver (only vmxnet3 + vm3d +
263
+ vmusbmouse), so the tools MSI skips its own service
264
+ registration — vmtoolsd.exe lands present but no
265
+ 'VMware Tools' service, and the runner then hangs at
266
+ "Waiting for the guest IP". The service is registered by
267
+ the final-verification provisioner (sandbox.pkr.hcl), not
268
+ here: a FirstLogonCommands CommandLine doing it (977
269
+ bytes of new code) broke Windows Setup at first boot
270
+ ("Windows could not complete the installation" → WinRM
271
+ never comes up), so the unattend command must stay small.
272
+ 3. Wait for the NIC to attach and complete DHCP, then force
273
+ the network category to Private (WinRM's AllowUnencrypted
274
+ refuses to apply on Public).
275
+ 4. Enable + configure WinRM (Basic + AllowUnencrypted) and
276
+ open port 5985. -->
277
+ <FirstLogonCommands>
278
+ <SynchronousCommand wcm:action="add">
279
+ <Order>1</Order>
280
+ <Description>Install vmxnet3 ARM64 driver into the driver store</Description>
281
+ <CommandLine>powershell.exe -NoProfile -ExecutionPolicy Bypass -Command "$ErrorActionPreference='Stop'; $found=$false; foreach ($l in 'D','E','F','G','H') { $p = ${l} + ':\vmxnet3.inf'; if (Test-Path $p) { pnputil.exe /add-driver $p /install | Out-Null; $found=$true; break } }; if (-not $found) { Write-Error 'vmxnet3.inf not found on D:..H: — unattend CD missing or relocated' }"</CommandLine>
282
+ </SynchronousCommand>
283
+ <SynchronousCommand wcm:action="add">
284
+ <Order>2</Order>
285
+ <Description>Install VMware Tools from the attached tools CD</Description>
286
+ <CommandLine>powershell.exe -NoProfile -ExecutionPolicy Bypass -Command "$ErrorActionPreference='Continue'; $inst=$null; foreach ($l in 'D','E','F','G','H') { $s=${l}+':\setup.exe'; $a=${l}+':\autorun.inf'; if ((Test-Path $s) -and (Test-Path $a) -and ((Get-Content $a -Raw -ErrorAction SilentlyContinue) -match 'open=setup')) { $inst=$s; break } }; if (-not $inst) { Write-Output 'VMware Tools CD not found — the image will lack guest tools (vmrun getGuestIPAddress/shared folders unavailable)'; exit 0 }; Write-Output ('Installing VMware Tools from ' + $inst); Start-Process $inst -ArgumentList '/S','/v','\"/qn REBOOT=R\"' -Wait | Out-Null; for ($i=0; $i -lt 48 -and -not (Test-Path 'C:\Program Files\VMware\VMware Tools\vmtoolsd.exe'); $i++) { Start-Sleep -Seconds 10 }; if (Test-Path 'C:\Program Files\VMware\VMware Tools\vmtoolsd.exe') { Write-Output 'VMware Tools installed (vmtoolsd.exe present)' } else { Write-Output 'VMware Tools install did not complete in ~8 min — see vmtoolsd.log' }"</CommandLine>
287
+ </SynchronousCommand>
288
+ <SynchronousCommand wcm:action="add">
289
+ <Order>3</Order>
290
+ <Description>Wait for network and force profile to Private</Description>
291
+ <CommandLine>powershell.exe -NoProfile -ExecutionPolicy Bypass -Command "for ($i=0; $i -lt 60; $i++) { $p = Get-NetConnectionProfile -ErrorAction SilentlyContinue; if ($p) { break }; Start-Sleep 2 }; Get-NetConnectionProfile | Set-NetConnectionProfile -NetworkCategory Private"</CommandLine>
292
+ </SynchronousCommand>
293
+ <SynchronousCommand wcm:action="add">
294
+ <Order>4</Order>
295
+ <Description>Enable WinRM service</Description>
296
+ <CommandLine>powershell.exe -NoProfile -ExecutionPolicy Bypass -Command "Set-Service -Name WinRM -StartupType Automatic; Start-Service WinRM"</CommandLine>
297
+ </SynchronousCommand>
298
+ <SynchronousCommand wcm:action="add">
299
+ <Order>5</Order>
300
+ <Description>Configure WinRM listener and auth</Description>
301
+ <CommandLine>powershell.exe -NoProfile -ExecutionPolicy Bypass -Command "winrm quickconfig -quiet; winrm set winrm/config/service '@{AllowUnencrypted=\"true\"}'; winrm set winrm/config/service/auth '@{Basic=\"true\"}'"</CommandLine>
302
+ </SynchronousCommand>
303
+ <SynchronousCommand wcm:action="add">
304
+ <Order>6</Order>
305
+ <Description>Open firewall for WinRM</Description>
306
+ <CommandLine>powershell.exe -NoProfile -ExecutionPolicy Bypass -Command "New-NetFirewallRule -Name 'WinRM HTTP-In' -DisplayName 'WinRM HTTP-In' -Profile Any -LocalPort 5985 -Protocol TCP -Action Allow"</CommandLine>
307
+ </SynchronousCommand>
308
+ </FirstLogonCommands>
309
+ </component>
310
+ </settings>
311
+ </unattend>