Files
cookbook-monasca-agent/recipes/default.rb
Tim Kuhlman 0058373a3d Fix for new keystoneclient requirements
Change-Id: I88939df1f1fda8eae18ae74227bd38a3f4b64cff
2014-07-25 11:46:45 -06:00

24 lines
742 B
Ruby

# encoding: UTF-8#
#
include_recipe 'python'
# Pre-reqs that when installed by os package avoid compilation by pip
%w[python-pymongo python-yaml supervisor sysstat libxml2-dev libxslt1-dev].each do |pkg_name|
package pkg_name do
action :install
end
end
settings = data_bag_item(node[:mon_agent][:data_bag], 'mon_agent')
execute 'mon-setup' do
action :nothing
command "/usr/local/bin/mon-setup -u #{settings['username']} -p #{settings['password']} -s #{settings['service']} --keystone_url #{settings['keystone_url']} --project_name #{settings['project_name']} --mon_url #{settings['mon_api_url']}"
end
python_pip 'mon-agent' do
action :install
notifies :run, 'execute[mon-setup]'
end
include_recipe 'mon_agent::plugin_cfg'