-
Notifications
You must be signed in to change notification settings - Fork 93
/
hyperv-windows-2012R2-serverstandard-amd64.json
65 lines (65 loc) · 2.5 KB
/
hyperv-windows-2012R2-serverstandard-amd64.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
{
"variables": {
"vm_name": "windows2012r2",
"cpu": "2",
"ram_size": "2048",
"disk_size": "41440",
"iso_url": "http://care.dlservice.microsoft.com/dl/download/6/2/A/62A76ABB-9990-4EFC-A4FE-C7D698DAEB96/9600.17050.WINBLUE_REFRESH.140317-1640_X64FRE_SERVER_EVAL_EN-US-IR3_SSS_X64FREE_EN-US_DV9.ISO",
"iso_checksum_type": "sha1",
"iso_checksum": "849734F37346385DAC2C101E4AACBA4626BB141C",
"hyperv_switchname": "{{env `hyperv_switchname`}}",
"username" : "vagrant",
"password" : "vagrant"
},
"builders": [
{
"vm_name":"{{user `vm_name`}}",
"type": "hyperv-iso",
"disk_size": "{{user `disk_size`}}",
"floppy_files": [],
"secondary_iso_images": [
"./windows/windows-2012R2-serverstandard-amd64/answer.iso"
],
"http_directory": "./windows/common/http/",
"boot_wait": "0s",
"boot_command": [
"a<enter><wait>a<enter><wait>a<enter><wait>a<enter>"
],
"guest_additions_mode":"disable",
"iso_url": "{{user `iso_url`}}",
"iso_checksum_type": "{{user `iso_checksum_type`}}",
"iso_checksum": "{{user `iso_checksum`}}",
"communicator":"winrm",
"winrm_username": "{{user `username`}}",
"winrm_password": "{{user `password`}}",
"winrm_timeout" : "6h",
"shutdown_command": "IF EXIST a:\\run-sysprep.cmd (CALL a:\\run-sysprep.cmd) ELSE (IF EXIST e:\\run-sysprep.cmd (CALL e:\\run-sysprep.cmd) ELSE (CALL f:\\run-sysprep.cmd)) &IF \"%ERRORLEVEL%\" == \"0\" (ECHO \"Shutdown script succeeded with exit code = %ERRORLEVEL%\" &EXIT 0) ELSE (ECHO \"Shutdown script failed with exit code = %ERRORLEVEL%\" &EXIT %ERRORLEVEL%)",
"ram_size": "{{user `ram_size`}}",
"cpu": "{{user `cpu`}}",
"generation": 2,
"switch_name":"{{user `hyperv_switchname`}}",
"enable_secure_boot":true
}],
"provisioners": [{
"type": "powershell",
"elevated_user": "{{user `username`}}",
"elevated_password": "{{user `password`}}",
"scripts": [
"./windows/common/Reset-ClientWSUSSetting.ps1",
"./windows/common/install-7zip.ps1",
"./windows/common/install-chef.ps1",
"./windows/common/compile-dotnet-assemblies.ps1",
"./windows/common/cleanup.ps1",
"./windows/common/ultradefrag.ps1",
"./windows/common/optimize-drive.ps1",
"./windows/common/sdelete.ps1"
]
}],
"post-processors": [
{
"type": "vagrant",
"keep_input_artifact": false,
"output": "{{.Provider}}_windows-2012r2_chef.box"
}
]
}