include_recipe "apache::ssl"
chef_platform = case node[:platform_version]
- when "12.10" then "12.04"
- when "14.04" then "12.04"
- else node[:platform_version]
+ when "12.10" then "12.04"
+ when "14.04" then "12.04"
+ else node[:platform_version]
end
chef_package = "chef-server_#{node[:chef][:server][:version]}_amd64.deb"
end
Dir.glob("/var/cache/chef/chef-server_*.deb").each do |deb|
- if deb != "/var/cache/chef/#{chef_package}"
- file deb do
- action :delete
- backup false
- end
+ next if deb == "/var/cache/chef/#{chef_package}"
+
+ file deb do
+ action :delete
+ backup false
end
end
service "chef-server-runsvdir" do
provider Chef::Provider::Service::Upstart
- action [ :enable, :start ]
+ action [:enable, :start]
supports :status => true, :restart => true, :reload => true
end