Skip to content

Commit

Permalink
Switch back to using rabbitmq-plugins from system path, drop Puppet 3…
Browse files Browse the repository at this point in the history
… conditional (voxpupuli#566)
  • Loading branch information
William Yardley committed Sep 12, 2017
1 parent 111532c commit fba5e9f
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions lib/puppet/provider/rabbitmq_plugin/rabbitmqplugins.rb
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
require File.expand_path(File.join(File.dirname(__FILE__), '..', 'rabbitmqctl'))
Puppet::Type.type(:rabbitmq_plugin).provide(:rabbitmqplugins, parent: Puppet::Provider::Rabbitmqctl) do
case Facter.value(:osfamily)
when 'RedHat'
has_command(:rabbitmqplugins, '/usr/lib/rabbitmq/bin/rabbitmq-plugins') { environment HOME: '/tmp' }
else
has_command(:rabbitmqplugins, 'rabbitmq-plugins') { environment HOME: '/tmp' }
path = ENV['PATH'] + ':/usr/sbin:/usr/lib/rabbitmq/bin'
has_command(:rabbitmqplugins, 'rabbitmq-plugins') do
environment PATH: path, HOME: '/tmp'
end

defaultfor feature: :posix
Expand Down

0 comments on commit fba5e9f

Please sign in to comment.