]> git.openstreetmap.org Git - chef.git/blobdiff - cookbooks/oxidized/recipes/default.rb
oxidized: fix broken usage of ssh_known_hosts_entry flush
[chef.git] / cookbooks / oxidized / recipes / default.rb
index 280efad594e0d997fd0bd2d8a8ed61e3eb73ce41..014955f743c331fe55adad8735ec35721d04785c 100644 (file)
@@ -107,12 +107,17 @@ execute "/opt/oxidized/.ssh/id_rsa.pub" do
   notifies :restart, "service[oxidized]"
 end
 
-ssh_known_hosts_entry 'github.com' do
+ssh_known_hosts_entry "github.com" do
   file_location "/opt/oxidized/.ssh/known_hosts"
   owner "oxidized"
   group "oxidized"
 end
 
+ssh_known_hosts_entry "github.com_flush" do
+  action :flush
+  file_location "/opt/oxidized/.ssh/known_hosts"
+end
+
 directory "/var/lib/oxidized" do
   owner "oxidized"
   group "oxidized"
@@ -141,6 +146,7 @@ systemd_service "oxidized" do
   after "network.target"
   user "oxidized"
   working_directory "/opt/oxidized/daemon"
+  runtime_directory "oxidized"
   exec_start "#{node[:ruby][:bundle]} exec oxidized"
   environment "OXIDIZED_HOME" => "/etc/oxidized",
               "OXIDIZED_LOGS" => "/var/log/oxidized"