{
"variables": {
"ssh_name": "admin",
"ssh_pass": "admin",
"ip": "10.0.1.1",
"netmask": "255.255.0.0",
"gateway": "10.0.0.254"
},
"builders": [{
"type": "virtualbox-iso",
"headless": "true",
"vboxmanage": [
["modifyvm", "{{.Name}}", "--acpi", "on"],
["modifyvm", "{{.Name}}", "--ioapic", "on"],
["modifyvm", "{{.Name}}", "--longmode", "on"],
["modifyvm", "{{.Name}}", "--cpus", "1"],
["modifyvm", "{{.Name}}", "--memory", "2048"],
["modifyvm", "{{.Name}}", "--vram", "9"],
["modifyvm", "{{.Name}}", "--nic1", "bridged"],
["modifyvm", "{{.Name}}", "--bridgeadapter1", "net2"],
["modifyvm", "{{.Name}}", "--vrde", "on"],
["modifyvm", "{{.Name}}", "--vrdeaddress", "10.0.250.10"]
],
"vrdp_port_min": 42000,
"vrdp_port_max": 42100,
"disk_size": 16000,
"guest_os_type": "FreeBSD_64",
"guest_additions_mode": "disable",
"iso_url": "/mnt//ISO/my.iso",
"iso_checksum": "972fb9aff8403075ad69994ea50cef3e",
"iso_checksum_type": "md5",
"ssh_skip_nat_mapping": "true",
"ssh_host": "{{user `ip`}}",
"ssh_port": 22,
"ssh_username": "{{user `ssh_name`}}",
"ssh_password": "{{user `ssh_pass`}}",
"ssh_wait_timeout": "15m",
"shutdown_command": "echo {{user `ssh_pass`}} | sudo -S shutdown -P now",
"boot_wait" : "10s",
"boot_command" : [
"<enter><wait10><wait10><left><enter><wait10><wait10>",
"<wait10><wait10><wait10><wait10><wait10><wait10><wait10><wait10><wait10>",
"<wait10><wait10><wait10><wait10><wait10><wait10><wait10>",
"{{user `ssh_name`}}",
"<wait><enter>",
"{{user `ssh_pass`}}",
"<wait><enter>",
"<wait><enter><wait><enter><wait><enter><wait>",
"<end><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs>",
"{{user `ip`}}<down>",
"<end><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs>",
"{{user `netmask`}}<down>",
"{{user `gateway`}}",
"<enter><wait><enter><wait><enter><wait10><wait5><enter>t<enter><enter>"
]
}],
"post-processors": [{
"type": "vagrant",
"output": "my.box"
}]
}
2016/04/27 10:59:01 packer: 2016/04/27 10:59:01 [INFO] Waiting for SSH, up to timeout: 15m0s
2016/04/27 10:59:01 ui: ==> virtualbox-iso: Waiting for SSH to become available...
2016/04/27 10:59:01 packer: 2016/04/27 10:59:01 [INFO] Attempting SSH connection...
2016/04/27 10:59:01 packer: 2016/04/27 10:59:01 reconnecting to TCP connection for SSH
2016/04/27 10:59:01 packer: 2016/04/27 10:59:01 handshaking with SSH
2016/04/27 10:59:03 packer: 2016/04/27 10:59:03 handshake error: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none password], no supported methods remain
2016/04/27 10:59:03 packer: 2016/04/27 10:59:03 [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none password], no supported methods remain
2016/04/27 10:59:03 packer: 2016/04/27 10:59:03 [DEBUG] Detected authentication error. Increasing handshake attempts.
[...] Same logs x 8
2016/04/27 11:00:22 packer: 2016/04/27 11:00:22 [INFO] Attempting SSH connection...
2016/04/27 11:00:22 packer: 2016/04/27 11:00:22 reconnecting to TCP connection for SSH
2016/04/27 11:00:22 packer: 2016/04/27 11:00:22 handshaking with SSH
2016/04/27 11:00:23 packer: 2016/04/27 11:00:23 handshake error: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none password], no supported methods remain
2016/04/27 11:00:23 packer: 2016/04/27 11:00:23 [DEBUG] SSH handshake err: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none password], no supported methods remain
2016/04/27 11:00:23 packer: 2016/04/27 11:00:23 [DEBUG] Detected authentication error. Increasing handshake attempts.
2016/04/27 11:00:23 ui error: ==> virtualbox-iso: Error waiting for SSH: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none password], no supported methods remain
2016/04/27 11:00:23 packer: 2016/04/27 11:00:23 Executing VBoxManage: []string{"controlvm", "packer-virtualbox-iso-1461747242", "poweroff"}
2016/04/27 11:00:24 packer: 2016/04/27 11:00:24 stdout:
2016/04/27 11:00:24 packer: 2016/04/27 11:00:24 stderr: 0%...10%...20%...30%...40%...50%...60%...70%...80%...90%...100%
2016/04/27 11:00:24 packer: 2016/04/27 11:00:24 Executing VBoxManage: []string{"storageattach", "packer-virtualbox-iso-1461747242", "--storagectl", "IDE Controller", "--port", "0", "--device", "1", "--medium", "none"}
2016/04/27 11:00:24 packer: 2016/04/27 11:00:24 stdout:
2016/04/27 11:00:24 packer: 2016/04/27 11:00:24 stderr:
2016/04/27 11:00:24 ui: ==> virtualbox-iso: Unregistering and deleting virtual machine...
2016/04/27 11:00:24 packer: 2016/04/27 11:00:24 Executing VBoxManage: []string{"unregistervm", "packer-virtualbox-iso-1461747242", "--delete"}
2016/04/27 11:00:24 packer: 2016/04/27 11:00:24 stdout:
2016/04/27 11:00:24 packer: 2016/04/27 11:00:24 stderr: 0%...10%...20%...30%...40%...50%...60%...70%...80%...90%...100%
2016/04/27 11:00:24 ui: ==> virtualbox-iso: Deleting output directory...
2016/04/27 11:00:24 ui error: Build 'virtualbox-iso' errored: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none password], no supported methods remain
2016/04/27 11:00:24 Builds completed. Waiting on interrupt barrier...
2016/04/27 11:00:24 machine readable: error-count []string{"1"}
2016/04/27 11:00:24 ui error:
==> Some builds didn't complete successfully and had errors:
2016/04/27 11:00:24 machine readable: virtualbox-iso,error []string{"ssh: handshake failed: ssh: unable to authenticate, attempted methods [none password], no supported methods remain"}
2016/04/27 11:00:24 ui error: --> virtualbox-iso: ssh: handshake failed: ssh: unable to authenticate, attempted methods [none password], no supported methods remain
2016/04/27 11:00:24 ui:
==> Builds finished but no artifacts were created.
2016/04/27 11:00:24 waiting for all plugin processes to complete...
2016/04/27 11:00:24 /usr/local/bin/packer: plugin process exited
2016/04/27 11:00:24 /usr/local/bin/packer: plugin process exited
...
I could connect to the guest via ssh while packer was trying ...
--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
GitHub Issues: https://github.com/mitchellh/packer/issues
IRC: #packer-tool on Freenode
---
You received this message because you are subscribed to the Google Groups "Packer" group.
To unsubscribe from this group and stop receiving emails from it, send an email to packer-tool...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/packer-tool/a966d446-57b3-49a7-a2f4-8e087a426da1%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
...
--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
GitHub Issues: https://github.com/mitchellh/packer/issues
IRC: #packer-tool on Freenode
---
You received this message because you are subscribed to the Google Groups "Packer" group.
To unsubscribe from this group and stop receiving emails from it, send an email to packer-tool...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/packer-tool/239cbb23-4220-48ef-8a60-f2bfd64af7ca%40googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/packer-tool/52c84782-7512-40e3-b76f-25fd3befd52c%40googlegroups.com.