vagrant-vsphere
vagrant-vsphere copied to clipboard
Tell plugin to wait for Windows sysprep
Hi, I ran into a minor issue as I described here: https://groups.google.com/forum/#!topic/vagrant-up/zX1g-HL90JU
The vm creation works well...
But since sysprep takes a bit of time to configure on the first boot, vagrant fails to authenticate with winrm. Vagrant tries to authenticate as soon as the machine is booted up.
So I was wondering if there is a way to wait for Windows to completely come up...
I think I can get around this by using triggers, but I'm not quite sure how it all works together.
I'm using the vagrant-triggers plugin, but the boot trigger doesn't seem to fire is it because this provider doesn't implement boot?
Never mind. Found an undocumented setting for winrm that lets you retry until it is up. This is important for sysprep windows which takes for ever...
https://github.com/mitchellh/vagrant/issues/7626
I had the same problem. config.winrm.max_tries did not fix it for me. I got it working with the changes in #199. This does the same thing as the Chef knife vsphere plugin.
In the main branch it will now wait for windows sysprep. Only problem is that it forces you to wait for customization now.
In #210 I have added support to optionally wait for customization to complete before continuing.