I am trying to provision a Windows machine from Mac OS X. When running:
ansible -i inventory winserver -m setup -c winrm -vvv
I get the following error:
`
No config file found; using defaults
An exception occurred during task execution. The full traceback is:
Traceback (most recent call last):
File “/usr/local/lib/python2.7/site-packages/ansible-2.0.0-py2.7.egg/ansible/executor/process/worker.py”, line 134, in run
shared_loader_obj,
File “/usr/local/lib/python2.7/site-packages/ansible-2.0.0-py2.7.egg/ansible/executor/task_executor.py”, line 118, in run
res = self._execute()
File “/usr/local/lib/python2.7/site-packages/ansible-2.0.0-py2.7.egg/ansible/executor/task_executor.py”, line 352, in _execute
self._connection.set_host_overrides(host=self._host)
File “/usr/local/lib/python2.7/site-packages/ansible-2.0.0-py2.7.egg/ansible/plugins/connection/winrm.py”, line 93, in set_host_overrides
if ‘@’ in self._winrm_user:
TypeError: argument of type ‘NoneType’ is not iterable
192.168.20.10 | FAILED! => {
“failed”: true,
“stdout”: “”
}
`
I ran:
pip install "pywinrm>=0.1.1"
and use the following Vagrantfile:
`
-- mode: ruby --
vi: set ft=ruby :
Vagrant.configure(2) do |windows|
windows.vm.box = “mwrock/Windows2012R2”
windows.vm.network “private_network”, ip: “192.168.20.10”
windows.vm.hostname = “winserver”
windows.vm.guest = :windows
windows.vm.communicator = “winrm”
end
`
Am I missing something or came across some bug?