]> git.openstreetmap.org Git - chef.git/blobdiff - cookbooks/kibana/recipes/default.rb
Fix new rubocop warnings
[chef.git] / cookbooks / kibana / recipes / default.rb
index 6a985ae344a12bd46ee7634ace62891521100e47..9f17df934666bc32c1da4f5af5cafb192514c72c 100644 (file)
@@ -1,4 +1,5 @@
 # coding: utf-8
 # coding: utf-8
+
 #
 # Cookbook Name:: kibana
 # Recipe:: default
 #
 # Cookbook Name:: kibana
 # Recipe:: default
@@ -20,7 +21,7 @@
 
 require "yaml"
 
 
 require "yaml"
 
-include_recipe "apache::ssl"
+include_recipe "apache"
 
 apache_module "proxy_http"
 
 
 apache_module "proxy_http"
 
@@ -68,6 +69,11 @@ systemd_service "kibana@" do
   after "network.target"
   user "kibana"
   exec_start "/opt/kibana-#{version}/bin/kibana -c /etc/kibana/%i.yml"
   after "network.target"
   user "kibana"
   exec_start "/opt/kibana-#{version}/bin/kibana -c /etc/kibana/%i.yml"
+  private_tmp true
+  private_devices true
+  protect_system "full"
+  protect_home true
+  no_new_privileges true
   restart "on-failure"
 end
 
   restart "on-failure"
 end
 
@@ -89,6 +95,7 @@ node[:kibana][:sites].each do |name, details|
   service "kibana@#{name}" do
     action [:enable, :start]
     supports :status => true, :restart => true, :reload => false
   service "kibana@#{name}" do
     action [:enable, :start]
     supports :status => true, :restart => true, :reload => false
+    subscribes :restart, "systemd_service[kibana@]"
   end
 
   ssl_certificate details[:site] do
   end
 
   ssl_certificate details[:site] do