Skip to content

Commit

Permalink
Merge pull request StefanScherer#231 from mariusmuntean/my
Browse files Browse the repository at this point in the history
Added a builder for Parallels
  • Loading branch information
StefanScherer authored Dec 20, 2019
2 parents c278ec9 + f061083 commit f2a18b4
Show file tree
Hide file tree
Showing 3 changed files with 50 additions and 0 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
## Unreleased
* Fixed issue with Console Output (#245)
* Added a Parallels builder for Windows 2019 with Docker

## v1.24 (June 8th, 2015)

Expand Down
18 changes: 18 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -183,6 +183,24 @@ You can use the following sample command to build a KVM/qemu box:
packer build --only=qemu --var virtio_win_iso=./virtio-win.iso ./windows_2019_docker.json
```

### Parallels support

In case you're using Parallels, you can now build the `Windows Server 2019 with Docker` VM.

Prerequisites:
* Parallels Pro or Business, version 11 and up.
* Vagrant Parallels Provider: https://github.com/Parallels/vagrant-parallels

You can use the following sample command to build a Parallels VM:

```
packer build --only=parallels-iso windows_2019_docker.json
```


The Parallels builder config turns `efi boot` off in order to use the same answer file like all the other builders. If you find you need to turn `efi boot` on then make sure to adjust the appropriate answer file, especially the section regarding the partitioning of the disk.
If you need to further customize the VM, consult the documentation at https://www.packer.io/docs/builders/parallels-iso.html.

### Using .box Files With Vagrant

The generated box files include a Vagrantfile template that is suitable for use
Expand Down
31 changes: 31 additions & 0 deletions windows_2019_docker.json
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,37 @@
"winrm_timeout": "{{user `winrm_timeout`}}",
"winrm_username": "vagrant"
},
{
"boot_wait": "2m",
"communicator": "winrm",
"cpus": 2,
"disk_size": "{{user `disk_size`}}",
"floppy_files": [
"{{user `autounattend`}}",
"./scripts/disable-screensaver.ps1",
"./scripts/disable-winrm.ps1",
"./scripts/docker/enable-winrm.ps1",
"./scripts/docker/2016/install-containers-feature.ps1",
"./scripts/microsoft-updates.bat",
"./scripts/win-updates.ps1"
],
"guest_os_type": "win-2019",
"iso_checksum": "{{user `iso_checksum`}}",
"iso_checksum_type": "{{user `iso_checksum_type`}}",
"iso_url": "{{user `iso_url`}}",
"memory": 4096,
"shutdown_command": "shutdown /s /t 10 /f /d p:4:1 /c \"Packer Shutdown\"",
"type": "parallels-iso",
"parallels_tools_flavor": "win",
"prlctl": [
["set", "{{.Name}}", "--adaptive-hypervisor", "on"],
["set", "{{.Name}}", "--efi-boot", "off"]
],
"vm_name": "WindowsServer2019Docker",
"winrm_password": "vagrant",
"winrm_timeout": "{{user `winrm_timeout`}}",
"winrm_username": "vagrant"
},
{
"boot_wait": "2m",
"communicator": "winrm",
Expand Down

0 comments on commit f2a18b4

Please sign in to comment.