ansible not reading group_vars/windows.yml

143 views
Skip to first unread message

pixel fairy

unread,
Feb 6, 2017, 9:05:09 AM2/6/17
to Ansible Project
seems ansible is not reading group_vars/windows.yml 
tried renaming to group_vars/windows same result

$ ansible --version
ansible
2.2.1.0

$ ansible windows
--list-hosts
  hosts
(1):
    ex
-domain1

$ cat group_vars
/windows.yml
ansible_user
: Administrator
ansible_port
: 5986
ansible_connection
: winrm
ansible_winrm_server_cert_validation
: ignore


$ ansible windows
-m debug -a msg="{{ansible_user}}"
ex
-domain1 | SUCCESS => {
   
"msg": "root"
}

$ cat ansible
.cfg
[defaults]
inventory
= ./inventory
remote_user
= root
roles_path
= ./roles

Message has been deleted

Matt Davis

unread,
Feb 6, 2017, 5:36:33 PM2/6/17
to Ansible Project
Hrm, running this exact stuff works fine for me on 2.2.1 (from source).

pixel fairy

unread,
Feb 6, 2017, 5:41:47 PM2/6/17
to Ansible Project
my control machine is ubuntu 16.04, ansible and winrm installed with pip. whats yours? ill try from source.

Matt Davis

unread,
Feb 6, 2017, 5:50:13 PM2/6/17
to Ansible Project
Fedora 25, but shouldn't matter unless somebody horribly broke something in packaging...

Matt Davis

unread,
Feb 6, 2017, 5:50:26 PM2/6/17
to Ansible Project
(especially since you installed from pip)

pixel fairy

unread,
Feb 6, 2017, 6:48:23 PM2/6/17
to Ansible Project
group_vars was in the playbooks directory. moved it to inventory and it worked. group_vars/all
worked fine from the playbooks directory. 
 
On Monday, February 6, 2017 at 2:50:13 PM UTC-8, Matt Davis wrote:
Fedora 25, but shouldn't matter unless somebody horribly broke something in packaging...

i think ubuntu broke the packaging. cant get anything to install from PPA. always get "does not have a release file".
Reply all
Reply to author
Forward
0 new messages