Permalink
Browse files

Merge pull request #2 from jhowarth/COOK-1125

[COOK-1125] - Add centos/redhat support to cron recipe.
  • Loading branch information...
jtimberman committed Mar 22, 2012
2 parents 3c93052 + 7308a02 commit a387b1d73a44e19f5a418eb70aacd7b73cb530ec
Showing with 13 additions and 1 deletion.
  1. +13 −1 recipes/default.rb
View
@@ -17,6 +17,18 @@
# limitations under the License.
#
-package "cron" do
+cron_package = case node['platform']
+when 'centos', 'redhat'
+ node.platform_version.to_f >= 6.0 ? "cronie" : "vixie-cron"
+else
+ "cron"
+end
+
+package cron_package do
action :upgrade
end
+
+service "crond" do
+ action [:start, :enable]
+end
+

0 comments on commit a387b1d

Please sign in to comment.