{"action":"created","issue":{"url":"https://api.github.com/repos/hashicorp/packer/issues/5605","repository_url":"https://api.github.com/repos/hashicorp/packer","labels_url":"https://api.github.com/repos/hashicorp/packer/issues/5605/labels{/name}","comments_url":"https://api.github.com/repos/hashicorp/packer/issues/5605/comments","events_url":"https://api.github.com/repos/hashicorp/packer/issues/5605/events","html_url":"https://github.com/hashicorp/packer/issues/5605","id":275111432,"number":5605,"title":"Hyper-V MINIX: No network hardware interfaces detected!","user":{"login":"mcandre","id":5316,"avatar_url":"https://avatars1.githubusercontent.com/u/5316?v=4","gravatar_id":"","url":"https://api.github.com/users/mcandre","html_url":"https://github.com/mcandre","followers_url":"https://api.github.com/users/mcandre/followers","following_url":"https://api.github.com/users/mcandre/following{/other_user}","gists_url":"https://api.github.com/users/mcandre/gists{/gist_id}","starred_url":"https://api.github.com/users/mcandre/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mcandre/subscriptions","organizations_url":"https://api.github.com/users/mcandre/orgs","repos_url":"https://api.github.com/users/mcandre/repos","events_url":"https://api.github.com/users/mcandre/events{/privacy}","received_events_url":"https://api.github.com/users/mcandre/received_events","type":"User","site_admin":false},"labels":[{"id":507190989,"url":"https://api.github.com/repos/hashicorp/packer/labels/builder/hyperv","name":"builder/hyperv","color":"d4c5f9","default":false},{"id":483188343,"url":"https://api.github.com/repos/hashicorp/packer/labels/help%20wanted","name":"help wanted","color":"fbca04","default":true},{"id":33051542,"url":"https://api.github.com/repos/hashicorp/packer/labels/question","name":"question","color":"cc317c","default":true}],"state":"open","locked":false,"assignee":{"login":"kikitux","id":1255709,"avatar_url":"https://avatars2.githubusercontent.com/u/1255709?v=4","gravatar_id":"","url":"https://api.github.com/users/kikitux","html_url":"https://github.com/kikitux","followers_url":"https://api.github.com/users/kikitux/followers","following_url":"https://api.github.com/users/kikitux/following{/other_user}","gists_url":"https://api.github.com/users/kikitux/gists{/gist_id}","starred_url":"https://api.github.com/users/kikitux/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kikitux/subscriptions","organizations_url":"https://api.github.com/users/kikitux/orgs","repos_url":"https://api.github.com/users/kikitux/repos","events_url":"https://api.github.com/users/kikitux/events{/privacy}","received_events_url":"https://api.github.com/users/kikitux/received_events","type":"User","site_admin":false},"assignees":[{"login":"kikitux","id":1255709,"avatar_url":"https://avatars2.githubusercontent.com/u/1255709?v=4","gravatar_id":"","url":"https://api.github.com/users/kikitux","html_url":"https://github.com/kikitux","followers_url":"https://api.github.com/users/kikitux/followers","following_url":"https://api.github.com/users/kikitux/following{/other_user}","gists_url":"https://api.github.com/users/kikitux/gists{/gist_id}","starred_url":"https://api.github.com/users/kikitux/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kikitux/subscriptions","organizations_url":"https://api.github.com/users/kikitux/orgs","repos_url":"https://api.github.com/users/kikitux/repos","events_url":"https://api.github.com/users/kikitux/events{/privacy}","received_events_url":"https://api.github.com/users/kikitux/received_events","type":"User","site_admin":false}],"milestone":null,"comments":1,"created_at":"2017-11-18T21:30:27Z","updated_at":"2018-03-06T17:48:15Z","closed_at":null,"author_association":"CONTRIBUTOR","body":"FOR BUGS:\r\n\r\nThe Hyper-V provider does not appear to provide a virtual network interface supported by MINIX guests.\r\n\r\nIs there a way for packer JSON to configure Hyper-V to specify a different virtual network interface to the guest, perhaps a more generic interface that legacy guests integrate with more easily?\r\n\r\n# System\r\n\r\n- Packer version from `packer version`: `v1.1.3-dev`\r\n- Host platform: Windows 10 Pro\r\n\r\n# Configuration\r\n\r\nminix.json:\r\n\r\n```json\r\n{\r\n  \"builders\": [\r\n    {\r\n      \"type\": \"hyperv-iso\",\r\n      \"vm_name\": \"minix\",\r\n      \"iso_url\": \"minix_R3.4.0rc6-d5e4fc0.iso\",\r\n      \"iso_checksum_type\": \"md5\",\r\n      \"iso_checksum\": \"55f8ca78ee6bdb7c12c02c69a2925439\",\r\n      \"ssh_username\": \"vagrant\",\r\n      \"ssh_password\": \"vagrant\",\r\n      \"ssh_timeout\": \"1800s\",\r\n      \"disk_size\": 1000,\r\n      \"ram_size\": 1024,\r\n      \"boot_command\": [\r\n        \"<enter><wait10><wait10><wait10><wait10><wait10><wait10><wait10><wait10>\",\r\n        \"root<enter><wait>\",\r\n        \"setup<enter><enter><wait>\",\r\n        \"<enter><enter><wait10><wait10>\",\r\n        \"<enter><wait>\",\r\n        \"<enter><wait5>\",\r\n        \"yes<enter><wait10><wait10><wait10>\",\r\n        \"<enter><wait>\",\r\n        \"<enter><wait>\",\r\n        \"<enter><wait10><wait10><wait10><wait10><wait10><wait10><wait10><wait10><wait10><wait10><wait10><wait10><wait10><wait10><wait10><wait10><wait10><wait10>\",\r\n        \"<enter><wait>\",\r\n        \"<enter><wait>\",\r\n        \"<enter><wait>\"\r\n      ],\r\n      \"shutdown_command\": \"su root -c '/sbin/halt -p'\"\r\n    }\r\n  ],\r\n  \"provisioners\": [\r\n    {\r\n      \"type\": \"shell\",\r\n      \"execute_command\": \"{{.Vars}} su -m root -c 'sh \\\"{{.Path}}\\\"'\",\r\n      \"scripts\": [\r\n        \"boot-sshd.minix.sh\"\r\n      ]\r\n    }\r\n  ],\r\n  \"post-processors\": [\r\n    {\r\n      \"type\": \"vagrant\",\r\n      \"output\": \"minix-{{.Provider}}.box\",\r\n      \"compression_level\": \"9\",\r\n      \"vagrantfile_template\": \"Vagrantfile\"\r\n    }\r\n  ]\r\n}\r\n```\r\n\r\nThe rest of the `boot_command` steps are elided in order to highlight the network setup error. At this point, MINIX installation exits unsuccessfully, and even fails to properly write the installation to disk. If the guest is sent the \"reboot<enter>\" keyboard characters, the resulting boot does not actually enter the installed MINIX system, but instead boots again into a fresh live CD MINIX system, causing the `user add -m -G wheel vagrant<enter>` section to fail, as the live CD does not provide user/group modification features. The rest of the `boot_command`, which does work with the VirtualBox provider, is as follows:\r\n\r\n```json\r\n\"reboot<enter><wait10>\",\r\n\"<enter><wait10><wait10><wait10><wait10><wait10>\",\r\n\"root<enter><wait>\",\r\n\"user add -m -G wheel vagrant<enter><wait>\",\r\n\"passwd vagrant<enter><wait>\",\r\n\"vagrant<enter><wait>\",\r\n\"vagrant<enter><wait>\",\r\n\"vagrant<enter><wait>\",\r\n\"mkdir -p /home/vagrant/.ssh<enter><wait>\",\r\n\"echo 'ssh-rsa AAAAB3NzaC1yc2EAAAABIwAAAQEA6NF8iallvQVp22WDkTkyrtvp9eWW6A8YVr+kz4TjGYe7gHzIw+niNltGEFHzD8+v1I2YJ6oXevct1YeS0o9HZyN1Q9qgCgzUFtdOKLv6IedplqoPkcmF0aYet2PkEDo3MlTBckFXPITAMzF8dJSIFo9D8HfdOV0IAdx4O7PtixWKn5y2hMNG0zQPyUecp4pzC6kivAIhyfHilFR61RGL+GPXQ2MWZWFYbAGjyiYJnAmCP3NOTd0jMZEnDkbUvxhMmBYSdETk1rRgm+R4LOzFUGaHqHDLKLX+FIPKcF96hrucXzcWyLbIbEgE98OHlnVYCzRdK8jlqm8tehUc9c9WhQ== vagrant insecure public key' >/home/vagrant/.ssh/authorized_keys<enter><wait>\",\r\n\"chown -R vagrant: /home/vagrant/.ssh<enter><wait>\",\r\n\"chmod 0700 /home/vagrant/.ssh<enter><wait>\",\r\n\"chmod 0600 /home/vagrant/.ssh/authorized_keys<enter><wait>\",\r\n\"yes | pkgin update<enter><wait10>\",\r\n\"yes | pkgin install openssh<enter><wait10>\",\r\n\"sh /usr/pkg/etc/rc.d/sshd onestart<enter><wait>\"\r\n```\r\n\r\nboot-sshd.minix.sh:\r\n\r\n```sh\r\n#!/bin/sh\r\n\r\necho 'sshd=YES' >>/etc/rc.conf &&\r\n    mkdir -p /etc/rc.d &&\r\n    cp /usr/pkg/etc/rc.d/sshd /etc/rc.d/\r\n```\r\n\r\nVagrantfile:\r\n\r\n```ruby\r\nVagrant.configure(\"2\") do |config|\r\n  config.vm.guest = :netbsd\r\n  config.ssh.shell = \"sh\"\r\n  config.ssh.sudo_command = \"su -m root -c '%c'\"\r\n  config.vm.synced_folder '.', '/vagrant', disabled: true\r\nend\r\n```"},"comment":{"url":"https://api.github.com/repos/hashicorp/packer/issues/comments/370867539","html_url":"https://github.com/hashicorp/packer/issues/5605#issuecomment-370867539","issue_url":"https://api.github.com/repos/hashicorp/packer/issues/5605","id":370867539,"user":{"login":"tuxillo","id":130578,"avatar_url":"https://avatars2.githubusercontent.com/u/130578?v=4","gravatar_id":"","url":"https://api.github.com/users/tuxillo","html_url":"https://github.com/tuxillo","followers_url":"https://api.github.com/users/tuxillo/followers","following_url":"https://api.github.com/users/tuxillo/following{/other_user}","gists_url":"https://api.github.com/users/tuxillo/gists{/gist_id}","starred_url":"https://api.github.com/users/tuxillo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tuxillo/subscriptions","organizations_url":"https://api.github.com/users/tuxillo/orgs","repos_url":"https://api.github.com/users/tuxillo/repos","events_url":"https://api.github.com/users/tuxillo/events{/privacy}","received_events_url":"https://api.github.com/users/tuxillo/received_events","type":"User","site_admin":false},"created_at":"2018-03-06T17:48:15Z","updated_at":"2018-03-06T17:48:15Z","author_association":"NONE","body":"Hi,\r\n\r\nMaybe this helps?\r\nhttps://www.altaro.com/hyper-v/work-hyper-v-virtual-network-adapters/\r\n\r\nRegards,\r\nAntonio Huete"}}
{"actor":{"display_login":"tuxillo"}}