Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- template "/etc/monit/conf.d/#{app['id']}.monitrc" do
- if app['id'] = fdog
- source "fdog.monitrc.erb"
- else
- source "site.monitrc.erb"
- end
- notifies :run, "execute[monit]"
- variables(
- :local_ip => node.ec2.local_ipv4,
- :app_name => app['id'],
- :start_program => "/vitrue/bin/app_#{app['id']} start",
- :stop_program => "/vitrue/bin/app_#{app['id']} stop",
- :pid_file => "/var/run/vitrue/unicorn_#{app['id']}.pid"
- )
- only_if do ::File.directory?('/etc/monit/conf.d'); end
- end
Add Comment
Please, Sign In to add comment