Skip to content

Commit

Permalink
Fix #288 - No longer restart Consul automatically.
Browse files Browse the repository at this point in the history
This seems to have come up a few times in the recent past. The idea here
is that we do not want to update Consul because the Chef Client may be
running in parallel on all of the nodes and result in a Consul cluster
downtime. This separately also sends a SIGHUP (reload) when a
configuration change is made instead of restarting the agent (for the
same reasons).

Because of this change it means that there will no longer be seamless
upgrades. It will require an operator to restart the Consul process on
all of the machines. Or they're going to need to wait until the instance
restarts since it'll be picked up at the next boot.
  • Loading branch information
John Bellone committed Mar 17, 2016
1 parent 72de606 commit 80f4a1c
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions recipes/default.rb
Original file line number Diff line number Diff line change
Expand Up @@ -52,14 +52,13 @@
group node['consul']['service_group']
end
node['consul']['config'].each_pair { |k, v| r.send(k, v) }
notifies :restart, "consul_service[#{service_name}]", :delayed
notifies :reload, "consul_service[#{service_name}]", :delayed
end

install = consul_installation node['consul']['version'] do |r|
if node['consul']['installation']
node['consul']['installation'].each_pair { |k, v| r.send(k, v) }
end
notifies :restart, "consul_service[#{service_name}]", :delayed
end

consul_service service_name do |r|
Expand Down

0 comments on commit 80f4a1c

Please sign in to comment.