Adding in monit support for nova-compute

This commit is contained in:
galstrom21
2012-06-08 11:47:08 -05:00
parent c6c4cec624
commit 2a91ae6f91
2 changed files with 23 additions and 0 deletions

View File

@@ -117,6 +117,10 @@ when "fedora"
"mysqld" => {
"start" => "/usr/sbin/service mysqld start",
"stop" => "/usr/sbin/service mysqld stop"
},
"nova-compute" => {
"start" => "/usr/sbin/service openstack-nova-compute start",
"stop" => "/usr/sbin/service openstack-nova-compute stop"
}
}
}
@@ -151,6 +155,10 @@ when "ubuntu"
"mysqld" => {
"start" => "/usr/sbin/service mysql start",
"stop" => "/usr/sbin/service mysql stop"
},
"nova-compute" => {
"start" => "/usr/sbin/service nova-compute start",
"stop" => "/usr/sbin/service nova-compute stop"
}
}

View File

@@ -39,3 +39,18 @@ collectd_plugin "libvirt" do
)
end
########################################
########################################
# BEGIN MONIT SECTION
# TODO(shep): This needs to be encased in an if block for the monit_enabled environment toggle
include_recipe "monit::server"
platform_options = node["nova"]["platform"]
monit_procmon "nova-compute" do
process_name "nova-compute"
start_cmd platform_options["monit_commands"]["nova-compute"]["start"]
stop_cmd platform_options["monit_commands"]["nova-compute"]["stop"]
end
########################################