Created
January 28, 2014 15:40
-
-
Save BBB/8669932 to your computer and use it in GitHub Desktop.
Ansible Jinja Error
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- name: Push the conf | |
template: src=./templates/conf.json.j2 dest=~/conf.json.j2 owner=$ansible_ssh_user mode=0600 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#jinja2:variable_start_string:'[%' , variable_end_string:'%]' | |
{ | |
"key": [ | |
{ | |
"path": "[% hostname %]/{{ timestamp }}-{{ filename }}" | |
} | |
] | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
fatal: [<IP>] => Traceback (most recent call last): | |
File "/usr/local/lib/python2.7/site-packages/ansible/runner/__init__.py", line 394, in _executor | |
exec_rc = self._executor_internal(host, new_stdin) | |
File "/usr/local/lib/python2.7/site-packages/ansible/runner/__init__.py", line 485, in _executor_internal | |
return self._executor_internal_inner(host, self.module_name, self.module_args, inject, port, complex_args=complex_args) | |
File "/usr/local/lib/python2.7/site-packages/ansible/runner/__init__.py", line 685, in _executor_internal_inner | |
result = handler.run(conn, tmp, module_name, module_args, inject, complex_args) | |
File "/usr/local/lib/python2.7/site-packages/ansible/runner/action_plugins/template.py", line 91, in run | |
local_md5 = utils.md5s(resultant) | |
File "/usr/local/lib/python2.7/site-packages/ansible/utils/__init__.py", line 523, in md5s | |
digest.update(data) | |
TypeError: must be string or buffer, not dict |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment