Skip to content

Commit

Permalink
Merge pull request #27 from jubianchi/consul-restart-config
Browse files Browse the repository at this point in the history
Restart consul service on configuration change
  • Loading branch information
John Bellone committed Jul 29, 2014
2 parents 3548309 + 8fdfe2e commit 0973dca
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions recipes/_service.rb
Original file line number Diff line number Diff line change
Expand Up @@ -113,15 +113,15 @@
service 'consul' do
supports status: true, restart: true, reload: true
action [:enable, :start]
subscribes :reload, "file[#{node[:consul][:config_dir]}/default.json]", :delayed
subscribes :restart, "file[#{node[:consul][:config_dir]}/default.json]", :delayed
end
when 'runit'
include_recipe 'runit'

runit_service 'consul' do
supports status: true, restart: true, reload: true
action [:enable, :start]
subscribes :reload, "file[#{node[:consul][:config_dir]}/default.json]", :immediately
subscribes :restart, "file[#{node[:consul][:config_dir]}/default.json]", :immediately
log true
options(
consul_binary: "#{node[:consul][:install_dir]}/consul",
Expand Down

0 comments on commit 0973dca

Please sign in to comment.