X-Git-Url: https://git.openstreetmap.org./chef.git/blobdiff_plain/c4abdded449ba9f2905f78fb9d2c017a49f99b17..426929d413ee6b334ed1c5f3b5e46689055a641f:/cookbooks/nginx/definitions/nginx_site.rb?ds=inline diff --git a/cookbooks/nginx/definitions/nginx_site.rb b/cookbooks/nginx/definitions/nginx_site.rb index 51228d632..f6e1f3a4d 100644 --- a/cookbooks/nginx/definitions/nginx_site.rb +++ b/cookbooks/nginx/definitions/nginx_site.rb @@ -30,14 +30,12 @@ define :nginx_site, :action => [ :create ], :variables => {} do group "root" mode 0644 variables params[:variables].merge(:name => name, :directory => directory) - notifies :reload, resources(:service => "nginx") + notifies :restart, "service[nginx]" end - end - - if site_action.include?(:delete) + elsif site_action.include?(:delete) file "/etc/nginx/conf.d/#{name}.conf" do action :delete - notifies :restart, resources(:service => "nginx") + notifies :restart, "service[nginx]" end end end