]> git.openstreetmap.org Git - chef.git/commitdiff
Restart rails by name during log rotation
authorTom Hughes <tom@compton.nu>
Sat, 20 Nov 2021 00:02:56 +0000 (00:02 +0000)
committerTom Hughes <tom@compton.nu>
Sat, 20 Nov 2021 00:02:56 +0000 (00:02 +0000)
cookbooks/web/templates/default/logrotate.web.erb

index 7f9e1de77e20a55e7130c8678b3986f12135d687..8502f770cdf32320d9b15c48add9ad5228a740d2 100644 (file)
@@ -11,7 +11,7 @@
   sharedscripts
   postrotate
 <% if File.directory?("#{node[:web][:base_directory]}/rails") -%>
-    PASSENGER_INSTANCE_REGISTRY_DIR=<%= node[:passenger][:instance_registry_dir] %> /usr/bin/passenger-config restart-app --ignore-app-not-running <%= node[:web][:base_directory] %>/rails > /dev/null
+    PASSENGER_INSTANCE_REGISTRY_DIR=<%= node[:passenger][:instance_registry_dir] %> /usr/bin/passenger-config restart-app --ignore-app-not-running --name rails > /dev/null
 <% end -%>
 <% if File.directory?("#{node[:web][:base_directory]}/gpx-import") -%>
     /bin/systemctl try-reload-or-restart gpx-import