sensu / sensu-ansible

An Ansible role to deploy a fully dynamic Sensu stack!
https://ansible-sensu.readthedocs.io
MIT License
126 stars 96 forks source link

Syntax Error while loading YAML. missing quotes #121

Closed marji closed 6 years ago

marji commented 6 years ago

While provisioning Sensu on Ubuntu 16.04, executing this role from Ubuntu 17.10 with ansible 2.3.3.0, I'm getting this Syntax Error:

TASK [sensu : include] ********************************************************************************************************************************************************* fatal: [sensu]: FAILED! => {"failed": true, "reason": "Syntax Error while loading YAML.\n\n\nThe error appears to have been in '/home/mcermak/projects/ansible-project-sensu/roles/sensu/tasks/Ubuntu/main.yml': line 25, column 14, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending line appears to be:\n\n apt:\n name: {{ sensu_package }}\n ^ here\nWe could be wrong, but this one looks like it might be an issue with\nmissing quotes. Always quote template expression brackets when they\nstart a value. For instance:\n\n with_items:\n - {{ foo }}\n\nShould be written as:\n\n with_items:\n - \"{{ foo }}\"\n"}

marji commented 6 years ago

Here is the change which introduces this problem: https://github.com/sensu/sensu-ansible/commit/faf8f8245b2b8cb99b1efae6a24345b138117d2e#diff-5a08192dd2ac3337fc5c89f2fd980aa5R25