action :delete
end
+template "/etc/sudoers.d/taginfo" do
+ source "sudoers.erb"
+ owner "root"
+ group "root"
+ mode 0440
+end
+
node[:taginfo][:sites].each do |site|
name = site[:name]
directory = site[:directory] || "/srv/#{name}"
--- /dev/null
+# DO NOT EDIT - This file is being maintained by Chef
+
+# Allow taginfo to restart the web app
+taginfo ALL=(root) NOPASSWD: /usr/bin/passenger-config restart-app *
mv $ROOT/sources/taginfo-*.db $ROOT/sources/*/taginfo-*.db $ROOT/data
mv $ROOT/sources/download/* $ROOT/download
-passenger-config restart-app $ROOT/taginfo/web > /dev/null
+sudo /usr/bin/passenger-config restart-app $ROOT/taginfo/web > /dev/null
find $ROOT/sources/log -mtime +28 -delete