mantl / terraform.py

Ansible dynamic inventory script for parsing Terraform state files
Apache License 2.0
451 stars 122 forks source link

Don't set the ansible_ssh_port value #50

Closed netjunki closed 7 years ago

netjunki commented 8 years ago

I was trying to use this with Windows hosts in AWS and ran into a problem because the ansible_ssh_port value was set and this overrode the value I had set in a group_vars yml to configure WinRM.

I was able to fix the problem by removing the lines which defined the property and things started working at that point.

It also looks like this configuration key's name has been changed in Ansible 2.0. From http://docs.ansible.com/ansible/intro_inventory.html:

Ansible 2.0 has deprecated the “ssh” from ansible_ssh_user, ansible_ssh_host, and ansible_ssh_port to become ansible_user, ansible_host, and ansible_port. If you are using a version of Ansible prior to 2.0, you should continue using the older style variables (ansiblessh*). These shorter variables are ignored, without warning, in older versions of Ansible.

virtuald commented 7 years ago

👍