Skip to content

Commit

Permalink
Run monit reload only once, after configure hook
Browse files Browse the repository at this point in the history
  • Loading branch information
kzkn committed Jan 16, 2021
1 parent 74c57ec commit b565e7f
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 4 deletions.
2 changes: 0 additions & 2 deletions libraries/drivers_appserver_base.rb
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,6 @@ def add_appserver_monit
source 'appserver.monitrc.erb'
variables opts
end

context.execute 'monit reload'
end

def restart_monit
Expand Down
2 changes: 0 additions & 2 deletions libraries/drivers_worker_base.rb
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,6 @@ def add_worker_monit
cookbook opts[:source_cookbook].to_s
variables opts
end

context.execute 'monit reload'
end

def worker_monit_template_cookbook
Expand Down
2 changes: 2 additions & 0 deletions recipes/configure.rb
Original file line number Diff line number Diff line change
Expand Up @@ -35,4 +35,6 @@
webserver = Drivers::Webserver::Factory.build(self, application)

fire_hook(:configure, items: databases + [source, framework, appserver, worker, webserver])

execute 'which monit >/dev/null && monit reload'
end

0 comments on commit b565e7f

Please sign in to comment.