-
Notifications
You must be signed in to change notification settings - Fork 289
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
TripleO and Sensu without ssl, ssl still enabled in rabbitmq.json #1050
Comments
Thank you for the issue, we are looking into it. |
@davidmnoriega Could you provide me a way to reproduce having https://github.com/sensu/sensu-puppet/blob/master/tests/sensu-server.pp#L4-L19 Results in this:
If your set |
A link to the puppet configuration that you are using would be very helpful. |
We add this to our TripleO deploy data: resource_registry:
OS::TripleO::Services::SensuClient: ../puppet/services/monitoring/sensu-client.yaml
parameter_defaults:
MonitoringRabbitHost: x.x.x.x
MonitoringRabbitPort: 5672
MonitoringRabbitUserName: admin
MonitoringRabbitPassword: xxxxx
MonitoringRabbitUseSSL: false
MonitoringRabbitVhost: "/sensu"
SensuClientCustomConfig:
api:
warning: 10
critical: 20 TripleO deployment then renders the per node hieradata on each node and the sensu data is in "sensu::api": false,
"sensu::client": true,
"sensu::client_custom": {
"api": {
"critical": 20,
"warning": 10
},
"openstack": {
"auth_url": "http://172.16.235.200:5000/v2.0",
"password": "xxxxx",
"region": "regionOne",
"tenant_name": "admin",
"username": "admin"
}
},
"sensu::enterprise": false,
"sensu::enterprise_dashboard": false,
"sensu::install_repo": false,
"sensu::manage_user": false,
"sensu::rabbitmq_host": "x.x.x.x",
"sensu::rabbitmq_password": "xxxxx",
"sensu::rabbitmq_port": 5672,
"sensu::rabbitmq_ssl": false,
"sensu::rabbitmq_ssl_cert_chain": "",
"sensu::rabbitmq_ssl_private_key": "",
"sensu::rabbitmq_user": "admin",
"sensu::rabbitmq_vhost": "/sensu",
"sensu::redact": [
"password",
"passwd",
"pass",
"api_key",
"api_token",
"access_key",
"secret_key",
"private_key",
"secret"
],
"sensu::sensu_plugin_name": "rubygem-sensu-plugin",
"sensu::sensu_plugin_provider": "yum",
"sensu::server": false,
"sensu::version": "present", Yet {
"rabbitmq": {
"port": 5672,
"host": "x.x.x.x",
"user": "admin",
"password": "xxxxx",
"vhost": "/sensu",
"heartbeat": 30,
"prefetch": 1,
"ssl": {
}
}
} |
Could you please upgrade the module to the latest release and see if this is still an issue. |
That might be tricky because the version of openstack determines which CentOS repo is used, which is what determines package versions of things like the puppet-sensu package. I'll see if I can just install a newer version, but that might not be easy to do. Re-reading @treydock 's comment, I have a hunch that because the TripleO heat templates are building hieradata that set |
The issue is actually here: The default for the underlying |
I did try using a newer version of the package, puppet-sensu-2.53.0-1.338ae0egit.el7, and while I could manually install it, it has dependencies on a newer version of puppet than what the pike repos have available, so the puppet apply failed. I'll be submitting a patch to TripleO with my workaround(dont put cert/key into hiera if ssl is false) as I dont know how an updated sensu-puppet package would get distributed and backported into the various repos. Thanks |
@davidmnoriega There is a patch in #1053 that would require no changes to TripleO. It would prevent this module from enabling SSL when both cert and key are empty strings. |
Description of problem
What did you do?
Use OpenStack TripleO+OpsTools to deploy OpenStack, with monitoring enabled but no SSL
https://github.com/openstack/tripleo-heat-templates/blob/stable/pike/environments/monitoring-environment.yaml
What happened?
Sensu agents are not able to communicate with rabbitmq
What did you expect to happen?
Sensu agents to be able to communicate
How can someone reproduce the problem?
Deploy OpenStack using TripleO with monitoring but set
MonitoringRabbitUseSSL
to false(or not set at all as its default value is false)Command used and debugging output
Sensu agent logs
Platform and version information
Anything else to add that you think will be helpful?
Removing
ssl{}
from sensu's rabbitmq config fixed it and the agents are able to communicate with the sensu server. I dont know much about ruby, but my hunch is this bit of code https://github.com/sensu/sensu-puppet/blob/master/lib/puppet/provider/sensu_rabbitmq_config/json.rb#L35-L55It looks like it only checks the existence of the key ssl in the hiera data, not it's value? So even though we are setting that to false via TripleO, somehow the sensu puppet module is putting
ssl{}
into the config, enabling ssl. But like I mention, I dont know ruby, so I could be wrong on that.The text was updated successfully, but these errors were encountered: