Skip to content

Commit

Permalink
Slight update
Browse files Browse the repository at this point in the history
  • Loading branch information
EntropyWorks committed Feb 17, 2012
1 parent 7777494 commit 95de6f1
Showing 1 changed file with 15 additions and 13 deletions.
28 changes: 15 additions & 13 deletions ntp/recipes/default.rb
Expand Up @@ -24,28 +24,30 @@
end
end

package "ntp" do
action :install
unless platform?("freebsd")
package "ntp" do
action :install
end

# ntpstats dir doesn't exist on RHEL/CentOS
# It'd be better to not make assumptions about the target platform
%w{ /var/lib/ntp /var/log/ntpstats }.each do |ntpdir|
directory ntpdir do
owner "ntp"
group "ntp"
mode 0755
end
end
end

service node[:ntp][:service] do
action :start
end

# ntpstats dir doesn't exist on RHEL/CentOS
# It'd be better to not make assumptions about the target platform
%w{ /var/lib/ntp /var/log/ntpstats }.each do |ntpdir|
directory ntpdir do
owner "ntp"
group "ntp"
mode 0755
end
end

template "/etc/ntp.conf" do
source "ntp.conf.erb"
owner "root"
group "root"
group node[:ntp][:root_group]
mode 0644
notifies :restart, "service[ntp]"
end
Expand Down

0 comments on commit 95de6f1

Please sign in to comment.