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

ssl_generate.yml not working with ansible 2.4.0 #101

Closed d9pouces closed 6 years ago

d9pouces commented 6 years ago

ssl_generate.yml is not working anymore with Ansible 2.4 :

TASK [cmacrae.sensu : Generate SSL certs] **********************************************************************************************************************************************************************
 [WARNING]: As of Ansible 2.4, the parameter 'executable' is no longer supported with the 'command' module. Not using '/bin/bash'.

fatal: [X]: FAILED! => {"changed": false, "cmd": "_ /etc/sensu/ssl_generation/sensu_ssl_tool/ssl_certs.sh generate", "failed": true, "msg": "[Errno 2] No such file or directory: '_'", "rc": 2}

I think that transforming the line 26 of ssl_generate.yml could do the job

      command: "{{ __bash_path }} _ {{ sensu_config_path }}/ssl_generation/sensu_ssl_tool/ssl_certs.sh generate"
d9pouces commented 6 years ago

I also have a problem with 'tasks/plugins.yml', especially its line 26

when: sens_remote_plugins > 0.

Since sens_remote_plugins is a list, the comparison cannot be made against an integer.

jaredledvina commented 6 years ago

Hey @d9pouces, Are you still hitting that last error? Looking at https://github.com/sensu/sensu-ansible/blob/master/tasks/plugins.yml#L28, it almost looks like when you hit that there was a mistype.

I haven't been able to replicate that error with 2.4 but, perhaps I'm missing something.

jaredledvina commented 6 years ago

I'm going to close this out as I believe the issues are resolved here (at least, with 2.4 I can't reproduce them anymore). Let me know if I'm totally missing something and we can revisit this.