Closed gerard76 closed 6 years ago
Thanks for reporting this though I don't see that in scope of this cookbook, sensu_gem
is specifically for sensu embedded ruby. If you are not using it then you should use gem_package which sensu_gem
is just a wrapper for gem_package
specifically to help people with the embedded ruby.
See: https://github.com/sensu/sensu-chef/blob/v4.1.0/providers/gem.rb for example useage and give it the path the the non embedded ruby.
Also I don't recommend using a system wide ruby for sensu anyways as it can have system wide consequences for installing new gems. For example installing a new version of sesu-plugins-chef
in some cases would upgrade the actual chef-client
version which is probably not desirable.
@thomasriley @cwjohnston do you feel differently?
You are right, I can (and should) use gem_package.
In this case I am forced to use the system ruby because of incompatibilities between sensu ssl and the sensu-plugins-postgres package.
You can use this to work around the postgres issues I believe: https://github.com/sensu-plugins/sensu-pg
@gerard-leijdekkers any chance you could create a PR to document this for other users with this question? If not I will do it when I have the time (likely this weekend).
closed via #601
When embedded_ruby is set to false I expect sensu-gem not to use the embedded sensu ruby.
in Sensu::Helpers gem_binary is defined as
Because /opt/sensu/embedded/bin/gem is installed regardless of the embedded_ruby setting and the helper does not look at the setting the embedded sensu ruby is used for installing gems.
I expect the system ruby to be used when embedded_ruby is set to false.