Use the rabbitmq_config Chef InSpec audit resource to test configuration data for the RabbitMQ daemon located at /etc/rabbitmq/rabbitmq.config on Linux and Unix platforms.
This resource is distributed along with Chef InSpec itself. You can use it automatically.
This resource first became available in v1.20.0 of InSpec.
A rabbitmq_config resource block declares the RabbitMQ configuration data to be tested:
describe rabbitmq_config.params('rabbit', 'ssl_listeners') do
it { should cmp 5671 }
end
where
params is the list of parameters configured in the RabbitMQ config file{ should cmp 5671 } tests the value of rabbit.ssl_listeners as read from rabbitmq.config versus the value declared in the testThe following examples show how to use this Chef InSpec audit resource.
describe rabbitmq_config.params('rabbit', 'tcp_listeners') do
it { should eq [5672] }
end
For a full list of available matchers, please visit our matchers page.
© Chef Software, Inc.
Licensed under the Creative Commons Attribution 3.0 Unported License.
The Chef™ Mark and Chef Logo are either registered trademarks/service marks or trademarks/servicemarks of Chef, in the United States and other countries and are used with Chef Inc's permission.
We are not affiliated with, endorsed or sponsored by Chef Inc.
https://docs.chef.io/inspec/resources/rabbitmq_config/