diff --git a/ansible/ansible.cfg b/ansible/ansible.cfg index 88ed4b9cd..ff02063f7 100644 --- a/ansible/ansible.cfg +++ b/ansible/ansible.cfg @@ -43,6 +43,7 @@ ansible_python_interpreter = /NODEJS2/python-2017-04-12-py27/python27/bin/python home = /u [hosts:win] +ansible_become = false ansible_connection = winrm ansible_winrm_server_cert_validation = ignore diff --git a/ansible/plugins/inventory/nodejs_yaml.py b/ansible/plugins/inventory/nodejs_yaml.py index 3a7fd0625..b528450aa 100755 --- a/ansible/plugins/inventory/nodejs_yaml.py +++ b/ansible/plugins/inventory/nodejs_yaml.py @@ -243,6 +243,10 @@ def parse_yaml(hosts, config): hostvars.update({'ansible_become': True}) del metadata['user'] + if 'password' in metadata: + hostvars.update({'ansible_password': str(metadata['password'])}) + del metadata['password'] + hostvars.update(metadata) # add specific options from config