Created
September 10, 2014 17:46
-
-
Save scarolan/5bb84ffab9d9fe6d619c to your computer and use it in GitHub Desktop.
modules.rb
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Ohai.plugin(:Apache) do | |
require 'mixlib/shellout' | |
provides "apache/modules" | |
collect_data(:default) do | |
modules = Mixlib::ShellOut.new("apachectl -t -D DUMP_MODULES") | |
modules.run_command | |
apache Mash.new | |
apache[:modules] = modules.stdout | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment