A project is lengthy one,part of the logs
TASK (ansible-role-risk-splunkforwarder : Template partial configuration files) 2s
task path: /apps/picana/teamcity/instance1/work/ec2c18870087834/roles/ansible-role-risk-splunkforwarder/tasks/redhat_config.yml:7
Traceback (most recent call last)
File "/home/md01/.virtualenvs/AnsibleDeployment_4.10.0/lib/python3.8/site-packages/ansible/template/__init__.py", line 1100, in do_template
res = j2_concat(rf)
File "<template>", line 25, in root
File "/home/md01/.virtualenvs/AnsibleDeployment_4.10.0/lib/python3.8/site-packages/jinja2/runtime.py", line 903, in _fail_with_undefined_error
raise self._undefined_exception(self._undefined_message)
In my ansible-role-risk-splunkforwarder,tasks
I have redhatconfig.yml
- name: checking if splunk config exist
register: splunk_config_dir
stat:
path: "......."
- name: template partial configuration files
when: splunk_config_dir.stat.exists
templates:
.......
How to find he root cause? I double checked all the templates.