Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Open sidebar
Bob Tanner
packer-windows
Commits
30397a4e
Commit
30397a4e
authored
Nov 26, 2015
by
Stefan Scherer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove win7ult
parent
5ea213d2
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
0 additions
and
409 deletions
+0
-409
answer_files/7_ultimate/Autounattend.xml
answer_files/7_ultimate/Autounattend.xml
+0
-284
windows_7_ultimate.json
windows_7_ultimate.json
+0
-125
No files found.
answer_files/7_ultimate/Autounattend.xml
deleted
100644 → 0
View file @
5ea213d2
<?xml version="1.0" encoding="utf-8"?>
<unattend
xmlns=
"urn:schemas-microsoft-com:unattend"
>
<servicing/>
<settings
pass=
"windowsPE"
>
<component
xmlns:wcm=
"http://schemas.microsoft.com/WMIConfig/2002/State"
xmlns:xsi=
"http://www.w3.org/2001/XMLSchema-instance"
name=
"Microsoft-Windows-Setup"
processorArchitecture=
"amd64"
publicKeyToken=
"31bf3856ad364e35"
language=
"neutral"
versionScope=
"nonSxS"
>
<DiskConfiguration>
<Disk
wcm:action=
"add"
>
<CreatePartitions>
<CreatePartition
wcm:action=
"add"
>
<Order>
1
</Order>
<Type>
Primary
</Type>
<Extend>
true
</Extend>
</CreatePartition>
</CreatePartitions>
<ModifyPartitions>
<ModifyPartition
wcm:action=
"add"
>
<Extend>
false
</Extend>
<Format>
NTFS
</Format>
<Letter>
C
</Letter>
<Order>
1
</Order>
<PartitionID>
1
</PartitionID>
<Label>
Windows 7
</Label>
</ModifyPartition>
</ModifyPartitions>
<DiskID>
0
</DiskID>
<WillWipeDisk>
true
</WillWipeDisk>
</Disk>
<WillShowUI>
OnError
</WillShowUI>
</DiskConfiguration>
<UserData>
<AcceptEula>
true
</AcceptEula>
<FullName>
Vagrant Administrator
</FullName>
<Organization>
Vagrant Inc.
</Organization>
<!-- Product Key from http://technet.microsoft.com/en-us/library/jj612867.aspx -->
<ProductKey>
<!-- Do not uncomment the Key element if you are using trial ISOs -->
<!-- You must uncomment the Key element (and optionally insert your own key) if you are using retail or volume license ISOs -->
<!--<Key>33PXH-7Y6KF-2VJC9-XBBR8-HVTHH</Key>-->
<WillShowUI>
Never
</WillShowUI>
</ProductKey>
</UserData>
<ImageInstall>
<OSImage>
<InstallTo>
<DiskID>
0
</DiskID>
<PartitionID>
1
</PartitionID>
</InstallTo>
<WillShowUI>
OnError
</WillShowUI>
<InstallToAvailablePartition>
false
</InstallToAvailablePartition>
<InstallFrom>
<MetaData
wcm:action=
"add"
>
<Key>
/IMAGE/NAME
</Key>
<Value>
Windows 7 ULTIMATE
</Value>
</MetaData>
</InstallFrom>
</OSImage>
</ImageInstall>
</component>
<component
xmlns:wcm=
"http://schemas.microsoft.com/WMIConfig/2002/State"
xmlns:xsi=
"http://www.w3.org/2001/XMLSchema-instance"
name=
"Microsoft-Windows-International-Core-WinPE"
processorArchitecture=
"amd64"
publicKeyToken=
"31bf3856ad364e35"
language=
"neutral"
versionScope=
"nonSxS"
>
<SetupUILanguage>
<UILanguage>
en-US
</UILanguage>
</SetupUILanguage>
<InputLocale>
de-DE
</InputLocale>
<SystemLocale>
de-DE
</SystemLocale>
<UILanguage>
en-US
</UILanguage>
<UILanguageFallback>
en-US
</UILanguageFallback>
<UserLocale>
de-DE
</UserLocale>
</component>
</settings>
<settings
pass=
"offlineServicing"
>
<component
name=
"Microsoft-Windows-LUA-Settings"
processorArchitecture=
"amd64"
publicKeyToken=
"31bf3856ad364e35"
language=
"neutral"
versionScope=
"nonSxS"
>
<EnableLUA>
false
</EnableLUA>
</component>
</settings>
<settings
pass=
"oobeSystem"
>
<component
xmlns:wcm=
"http://schemas.microsoft.com/WMIConfig/2002/State"
xmlns:xsi=
"http://www.w3.org/2001/XMLSchema-instance"
name=
"Microsoft-Windows-Shell-Setup"
processorArchitecture=
"amd64"
publicKeyToken=
"31bf3856ad364e35"
language=
"neutral"
versionScope=
"nonSxS"
>
<UserAccounts>
<AdministratorPassword>
<Value>
vagrant
</Value>
<PlainText>
true
</PlainText>
</AdministratorPassword>
<LocalAccounts>
<LocalAccount
wcm:action=
"add"
>
<Password>
<Value>
vagrant
</Value>
<PlainText>
true
</PlainText>
</Password>
<Description>
Vagrant User
</Description>
<DisplayName>
vagrant
</DisplayName>
<Group>
administrators
</Group>
<Name>
vagrant
</Name>
</LocalAccount>
</LocalAccounts>
</UserAccounts>
<OOBE>
<HideEULAPage>
true
</HideEULAPage>
<HideWirelessSetupInOOBE>
true
</HideWirelessSetupInOOBE>
<NetworkLocation>
Home
</NetworkLocation>
<ProtectYourPC>
1
</ProtectYourPC>
</OOBE>
<AutoLogon>
<Password>
<Value>
vagrant
</Value>
<PlainText>
true
</PlainText>
</Password>
<Username>
vagrant
</Username>
<Enabled>
true
</Enabled>
</AutoLogon>
<FirstLogonCommands>
<SynchronousCommand
wcm:action=
"add"
>
<CommandLine>
cmd.exe /c powershell -Command "Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Force"
</CommandLine>
<Description>
Set Execution Policy 64 Bit
</Description>
<Order>
1
</Order>
<RequiresUserInput>
true
</RequiresUserInput>
</SynchronousCommand>
<SynchronousCommand
wcm:action=
"add"
>
<CommandLine>
C:\Windows\SysWOW64\cmd.exe /c powershell -Command "Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Force"
</CommandLine>
<Description>
Set Execution Policy 32 Bit
</Description>
<Order>
2
</Order>
<RequiresUserInput>
true
</RequiresUserInput>
</SynchronousCommand>
<SynchronousCommand
wcm:action=
"add"
>
<CommandLine>
cmd.exe /c winrm quickconfig -q
</CommandLine>
<Description>
winrm quickconfig -q
</Description>
<Order>
3
</Order>
<RequiresUserInput>
true
</RequiresUserInput>
</SynchronousCommand>
<SynchronousCommand
wcm:action=
"add"
>
<CommandLine>
cmd.exe /c winrm quickconfig -transport:http
</CommandLine>
<Description>
winrm quickconfig -transport:http
</Description>
<Order>
4
</Order>
<RequiresUserInput>
true
</RequiresUserInput>
</SynchronousCommand>
<SynchronousCommand
wcm:action=
"add"
>
<CommandLine>
cmd.exe /c winrm set winrm/config @{MaxTimeoutms="1800000"}
</CommandLine>
<Description>
Win RM MaxTimoutms
</Description>
<Order>
5
</Order>
<RequiresUserInput>
true
</RequiresUserInput>
</SynchronousCommand>
<SynchronousCommand
wcm:action=
"add"
>
<CommandLine>
cmd.exe /c winrm set winrm/config/winrs @{MaxMemoryPerShellMB="800"}
</CommandLine>
<Description>
Win RM MaxMemoryPerShellMB
</Description>
<Order>
6
</Order>
<RequiresUserInput>
true
</RequiresUserInput>
</SynchronousCommand>
<SynchronousCommand
wcm:action=
"add"
>
<CommandLine>
cmd.exe /c winrm set winrm/config/service @{AllowUnencrypted="true"}
</CommandLine>
<Description>
Win RM AllowUnencrypted
</Description>
<Order>
7
</Order>
<RequiresUserInput>
true
</RequiresUserInput>
</SynchronousCommand>
<SynchronousCommand
wcm:action=
"add"
>
<CommandLine>
cmd.exe /c winrm set winrm/config/service/auth @{Basic="true"}
</CommandLine>
<Description>
Win RM auth Basic
</Description>
<Order>
8
</Order>
<RequiresUserInput>
true
</RequiresUserInput>
</SynchronousCommand>
<SynchronousCommand
wcm:action=
"add"
>
<CommandLine>
cmd.exe /c winrm set winrm/config/client/auth @{Basic="true"}
</CommandLine>
<Description>
Win RM client auth Basic
</Description>
<Order>
9
</Order>
<RequiresUserInput>
true
</RequiresUserInput>
</SynchronousCommand>
<SynchronousCommand
wcm:action=
"add"
>
<CommandLine>
cmd.exe /c winrm set winrm/config/listener?Address=*+Transport=HTTP @{Port="5985"}
</CommandLine>
<Description>
Win RM listener Address/Port
</Description>
<Order>
10
</Order>
<RequiresUserInput>
true
</RequiresUserInput>
</SynchronousCommand>
<SynchronousCommand
wcm:action=
"add"
>
<CommandLine>
cmd.exe /c netsh advfirewall firewall set rule group="remote administration" new enable=yes
</CommandLine>
<Description>
Win RM adv firewall enable
</Description>
<Order>
11
</Order>
<RequiresUserInput>
true
</RequiresUserInput>
</SynchronousCommand>
<SynchronousCommand
wcm:action=
"add"
>
<CommandLine>
cmd.exe /c netsh firewall add portopening TCP 5985 "Port 5985"
</CommandLine>
<Description>
Win RM port open
</Description>
<Order>
12
</Order>
<RequiresUserInput>
true
</RequiresUserInput>
</SynchronousCommand>
<SynchronousCommand
wcm:action=
"add"
>
<CommandLine>
cmd.exe /c net stop winrm
</CommandLine>
<Description>
Stop Win RM Service
</Description>
<Order>
13
</Order>
<RequiresUserInput>
true
</RequiresUserInput>
</SynchronousCommand>
<SynchronousCommand
wcm:action=
"add"
>
<CommandLine>
cmd.exe /c sc config winrm start= auto
</CommandLine>
<Description>
Win RM Autostart
</Description>
<Order>
14
</Order>
<RequiresUserInput>
true
</RequiresUserInput>
</SynchronousCommand>
<SynchronousCommand
wcm:action=
"add"
>
<CommandLine>
cmd.exe /c net start winrm
</CommandLine>
<Description>
Start Win RM Service
</Description>
<Order>
15
</Order>
<RequiresUserInput>
true
</RequiresUserInput>
</SynchronousCommand>
<SynchronousCommand
wcm:action=
"add"
>
<CommandLine>
%SystemRoot%\System32\reg.exe ADD HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced\ /v HideFileExt /t REG_DWORD /d 0 /f
</CommandLine>
<Order>
16
</Order>
<Description>
Show file extensions in Explorer
</Description>
</SynchronousCommand>
<SynchronousCommand
wcm:action=
"add"
>
<CommandLine>
%SystemRoot%\System32\reg.exe ADD HKCU\Console /v QuickEdit /t REG_DWORD /d 1 /f
</CommandLine>
<Order>
17
</Order>
<Description>
Enable QuickEdit mode
</Description>
</SynchronousCommand>
<SynchronousCommand
wcm:action=
"add"
>
<CommandLine>
%SystemRoot%\System32\reg.exe ADD HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced\ /v Start_ShowRun /t REG_DWORD /d 1 /f
</CommandLine>
<Order>
18
</Order>
<Description>
Show Run command in Start Menu
</Description>
</SynchronousCommand>
<SynchronousCommand
wcm:action=
"add"
>
<CommandLine>
%SystemRoot%\System32\reg.exe ADD HKCU\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced\ /v StartMenuAdminTools /t REG_DWORD /d 1 /f
</CommandLine>
<Order>
19
</Order>
<Description>
Show Administrative Tools in Start Menu
</Description>
</SynchronousCommand>
<SynchronousCommand
wcm:action=
"add"
>
<CommandLine>
%SystemRoot%\System32\reg.exe ADD HKLM\SYSTEM\CurrentControlSet\Control\Power\ /v HibernateFileSizePercent /t REG_DWORD /d 0 /f
</CommandLine>
<Order>
20
</Order>
<Description>
Zero Hibernation File
</Description>
</SynchronousCommand>
<SynchronousCommand
wcm:action=
"add"
>
<CommandLine>
%SystemRoot%\System32\reg.exe ADD HKLM\SYSTEM\CurrentControlSet\Control\Power\ /v HibernateEnabled /t REG_DWORD /d 0 /f
</CommandLine>
<Order>
21
</Order>
<Description>
Disable Hibernation Mode
</Description>
</SynchronousCommand>
<SynchronousCommand
wcm:action=
"add"
>
<CommandLine>
cmd.exe /c wmic useraccount where "name='vagrant'" set PasswordExpires=FALSE
</CommandLine>
<Order>
22
</Order>
<Description>
Disable password expiration for vagrant user
</Description>
</SynchronousCommand>
<!-- WITHOUT WINDOWS UPDATES -->
<!--
<SynchronousCommand wcm:action="add">
<CommandLine>cmd.exe /c C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -File a:\dis-updates.ps1</CommandLine>
<Description>Disable Automatic Updates</Description>
<Order>97</Order>
<RequiresUserInput>true</RequiresUserInput>
</SynchronousCommand>
<SynchronousCommand wcm:action="add">
<CommandLine>cmd.exe /c C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -File a:\openssh.ps1 -AutoStart</CommandLine>
<Description>Install OpenSSH</Description>
<Order>99</Order>
<RequiresUserInput>true</RequiresUserInput>
</SynchronousCommand>
-->
<!-- END WITHOUT WINDOWS UPDATES -->
<!-- WITH WINDOWS UPDATES -->
<SynchronousCommand
wcm:action=
"add"
>
<CommandLine>
cmd.exe /c C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -File a:\dis-updates.ps1
</CommandLine>
<Description>
Disable Automatic Updates
</Description>
<Order>
97
</Order>
<RequiresUserInput>
true
</RequiresUserInput>
</SynchronousCommand>
<SynchronousCommand
wcm:action=
"add"
>
<CommandLine>
cmd.exe /c C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -File a:\win-updates.ps1 -MaxUpdatesPerCycle 30
</CommandLine>
<Description>
Install Windows Updates
</Description>
<Order>
100
</Order>
<RequiresUserInput>
true
</RequiresUserInput>
</SynchronousCommand>
<!-- END WITH WINDOWS UPDATES -->
</FirstLogonCommands>
<ShowWindowsLive>
false
</ShowWindowsLive>
</component>
</settings>
<settings
pass=
"specialize"
>
<component
name=
"Microsoft-Windows-Shell-Setup"
processorArchitecture=
"amd64"
publicKeyToken=
"31bf3856ad364e35"
language=
"neutral"
versionScope=
"nonSxS"
>
<OEMInformation>
<HelpCustomized>
false
</HelpCustomized>
</OEMInformation>
<!-- Rename computer here. -->
<ComputerName>
vagrant-2012
</ComputerName>
<TimeZone>
W. Europe Standard Time
</TimeZone>
<RegisteredOwner/>
</component>
<component
xmlns:wcm=
"http://schemas.microsoft.com/WMIConfig/2002/State"
xmlns:xsi=
"http://www.w3.org/2001/XMLSchema-instance"
name=
"Microsoft-Windows-Security-SPP-UX"
processorArchitecture=
"amd64"
publicKeyToken=
"31bf3856ad364e35"
language=
"neutral"
versionScope=
"nonSxS"
>
<SkipAutoActivation>
true
</SkipAutoActivation>
</component>
</settings>
<cpi:offlineImage
xmlns:cpi=
"urn:schemas-microsoft-com:cpi"
cpi:source=
"catalog:d:/sources/install_windows 7 ENTERPRISE.clg"
/>
</unattend>
windows_7_ultimate.json
deleted
100644 → 0
View file @
5ea213d2
{
"builders"
:
[
{
"type"
:
"vmware-iso"
,
"iso_url"
:
"file:///Users/stefan/iso/windows7-ultimate-x64.iso"
,
"iso_checksum_type"
:
"md5"
,
"iso_checksum"
:
"51f51abbddab7055c8ca8bafe4ca3123"
,
"headless"
:
false
,
"boot_wait"
:
"2m"
,
"ssh_username"
:
"vagrant"
,
"ssh_password"
:
"vagrant"
,
"ssh_wait_timeout"
:
"4h"
,
"shutdown_command"
:
"shutdown /s /t 10 /f /d p:4:1 /c
\"
Packer Shutdown
\"
"
,
"guest_os_type"
:
"windows7-64"
,
"tools_upload_flavor"
:
"windows"
,
"disk_size"
:
61440
,
"vnc_port_min"
:
5900
,
"vnc_port_max"
:
5980
,
"floppy_files"
:
[
"./answer_files/7_ultimate/Autounattend.xml"
,
"./scripts/dis-updates.ps1"
,
"./scripts/microsoft-updates.bat"
,
"./scripts/win-updates.ps1"
,
"./scripts/openssh.ps1"
,
"./scripts/unattend.xml"
],
"vmx_data"
:
{
"RemoteDisplay.vnc.enabled"
:
"false"
,
"RemoteDisplay.vnc.port"
:
"5900"
,
"memsize"
:
"2048"
,
"numvcpus"
:
"2"
,
"scsi0.virtualDev"
:
"lsisas1068"
}
},
{
"type"
:
"virtualbox-iso"
,
"iso_url"
:
"file:///Users/stefan/iso/windows7-ultimate-x64.iso"
,
"iso_checksum_type"
:
"md5"
,
"iso_checksum"
:
"51f51abbddab7055c8ca8bafe4ca3123"
,
"headless"
:
false
,
"boot_wait"
:
"2m"
,
"ssh_username"
:
"vagrant"
,
"ssh_password"
:
"vagrant"
,
"ssh_wait_timeout"
:
"4h"
,
"shutdown_command"
:
"shutdown /s /t 10 /f /d p:4:1 /c
\"
Packer Shutdown
\"
"
,
"guest_os_type"
:
"Windows7_64"
,
"disk_size"
:
61440
,
"floppy_files"
:
[
"./answer_files/7_ultimate/Autounattend.xml"
,
"./scripts/dis-updates.ps1"
,
"./scripts/microsoft-updates.bat"
,
"./scripts/win-updates.ps1"
,
"./scripts/openssh.ps1"
,
"./scripts/oracle-cert.cer"
,
"./scripts/unattend.xml"
],
"vboxmanage"
:
[
[
"modifyvm"
,
"{{.Name}}"
,
"--memory"
,
"2048"
],
[
"modifyvm"
,
"{{.Name}}"
,
"--cpus"
,
"2"
],
[
"modifyvm"
,
"{{.Name}}"
,
"--vrdeaddress"
,
"127.0.0.1"
],
[
"modifyvm"
,
"{{.Name}}"
,
"--vrdeport"
,
"13389"
],
[
"modifyvm"
,
"{{.Name}}"
,
"--vcpenabled"
,
"off"
],
[
"modifyvm"
,
"{{.Name}}"
,
"--vcpfile"
,
"windows_7.webm"
]
]
}
],
"provisioners"
:
[
{
"type"
:
"shell"
,
"remote_path"
:
"/tmp/script.bat"
,
"execute_command"
:
"{{.Vars}} cmd /c C:/Windows/Temp/script.bat"
,
"scripts"
:
[
"./scripts/vm-guest-tools.bat"
,
"./scripts/vagrant-ssh.bat"
,
"./scripts/dis-updates.bat"
,
"./scripts/enable-rdp.bat"
,
"./scripts/enable-winrm.bat"
]
},
{
"type"
:
"shell"
,
"inline"
:
[
"rm -rf /tmp/*"
]
}
],
"post-processors"
:
[
{
"type"
:
"vagrant"
,
"keep_input_artifact"
:
false
,
"output"
:
"windows_7_ultimate_{{.Provider}}.box"
,
"vagrantfile_template"
:
"vagrantfile-windows_7.template"
}
]
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment