Skip to content

Commit

Permalink
Merge pull request #969 from bugfood/missing-command
Browse files Browse the repository at this point in the history
add a workaround for rabbitmq_vhost when running with --noop or --tags
  • Loading branch information
wyardley authored Jan 3, 2024
2 parents 175d556 + f8bd2d8 commit 2605e30
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions lib/puppet/provider/rabbitmq_vhost/rabbitmqctl.rb
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,11 @@ def self.prefetch(resources)
# we only deal with vhost metadata >= version 3.11.0
def self.supports_metadata?
Puppet::Util::Package.versioncmp(rabbitmq_version, '3.11') >= 0
rescue Puppet::MissingCommand
# See comment on the definition of rabbitmqctl_list in rabbitmqctl_cli.rb;
# the same rationale applies here.
Puppet.debug('supports_metadata?: rabbitmqctl command not found; assuming rabbitmq is not installed')
false
end

def supports_metadata?
Expand Down

0 comments on commit 2605e30

Please sign in to comment.