Libvirt provider
Adding Packer Qemu builder: * Packer/answer_files/*_virtio: Install the virtio drivers from the ISO (NOT provided) * windows_*.json needs some manual tweaks to match the virtio drivers ISO path Adding Vagrant-libvirt provider: * Uses the QEMU qcow2 images provided by packer to build the DetectionLab * Vagrantfile needs manual tweaking to match libvirt's host configuration (backing store, network interfaces, etc) README: * Added separate README with instructions for libvirt
This commit is contained in:
@@ -1,5 +1,49 @@
|
||||
{
|
||||
"builders": [
|
||||
{
|
||||
"type": "qemu",
|
||||
"vm_name":"windows_10",
|
||||
"communicator": "winrm",
|
||||
"iso_url": "{{user `iso_url`}}",
|
||||
"iso_checksum_type": "{{user `iso_checksum_type`}}",
|
||||
"iso_checksum": "{{user `iso_checksum`}}",
|
||||
"headless": true,
|
||||
"boot_wait": "6m",
|
||||
"boot_command": "",
|
||||
"winrm_username": "vagrant",
|
||||
"winrm_password": "vagrant",
|
||||
"winrm_timeout": "4h",
|
||||
"shutdown_timeout": "2h",
|
||||
"shutdown_command": "a:/sysprep.bat",
|
||||
|
||||
"accelerator": "kvm",
|
||||
"disk_size": "{{user `disk_size`}}",
|
||||
|
||||
"output_directory": "{{ user `packer_build_dir`}}",
|
||||
|
||||
"qemuargs": [
|
||||
[ "-m", "2048"],
|
||||
[ "-smp", "2"],
|
||||
[ "-drive", "file={{ user `virtio_win_iso` }},media=cdrom,index=3" ],
|
||||
[ "-drive", "file={{ user `packer_build_dir`}}/{{ .Name }},if=virtio,cache=writeback,discard=ignore,format=qcow2,index=1" ]
|
||||
],
|
||||
|
||||
"floppy_files": [
|
||||
"{{user `autounattend_virtio`}}",
|
||||
"./floppy/WindowsPowershell.lnk",
|
||||
"./floppy/PinTo10.exe",
|
||||
"./scripts/fixnetwork.ps1",
|
||||
"./scripts/rearm-windows.ps1",
|
||||
"./scripts/disable-screensaver.ps1",
|
||||
"./scripts/disable-winrm.ps1",
|
||||
"./scripts/enable-winrm.ps1",
|
||||
"./scripts/microsoft-updates.bat",
|
||||
"./scripts/win-updates.ps1",
|
||||
"./scripts/unattend.xml",
|
||||
"./scripts/sysprep.bat"
|
||||
]
|
||||
|
||||
},
|
||||
{
|
||||
"type": "vmware-iso",
|
||||
"vm_name":"windows_10",
|
||||
@@ -141,6 +185,11 @@
|
||||
"iso_checksum_type": "sha256",
|
||||
"iso_url": "https://software-download.microsoft.com/download/pr/18362.30.190401-1528.19h1_release_svc_refresh_CLIENTENTERPRISEEVAL_OEMRET_x64FRE_en-us.iso",
|
||||
"autounattend": "./answer_files/10/Autounattend.xml",
|
||||
"disk_size": "61440"
|
||||
"disk_size": "61440",
|
||||
"virtio_win_iso": "./virtio-win.iso",
|
||||
"autounattend_virtio": "./answer_files/10_virtio/Autounattend.xml",
|
||||
"packer_build_dir": "/media/packer_build_dir/win10"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user