Sha256: 1dfb4f3283b32e90290f57c37126ea8dd6ec85bd77fc3b58cbf42fc917efe01f
Contents?: true
Size: 1.17 KB
Versions: 1
Compression:
Stored size: 1.17 KB
Contents
<% if fetch(:nginx_major_domain, false) %> <% domain_list = [fetch(:nginx_major_domain, "").to_s.gsub(/^\*?\./, "")] %> <% else %> <% domain_list = [] %> <% Array(fetch(:nginx_domains)).each do |domain| %> <% domain_list << domain.gsub(/^\*?\./, "") %> <% end %> <% end %> # Check domains on port 80 <%= "(and 443 if ssl is on)" if fetch(:nginx_use_ssl) %> for <%= fetch(:application) %> [<%= fetch(:stage) %>] <% domain_list.uniq.each do |domain| %> check host "<%= fetch(:monit_website_check_name, domain) %>" with address <%= domain %> <% if fetch(:nginx_use_ssl) %>if failed port 443 protocol https and certificate valid > 2 days then <%= monit_alert %><% end %> if failed <% if fetch(:nginx_use_ssl) %> port 443 protocol https <% else %> port 80 protocol http <% end %> <% if fetch(:monit_website_check_content, false) %> request "<%= fetch(:monit_website_check_path, '/') %>" content = "<%= fetch(:monit_website_check_text, '<!DOCTYPE html>') %>" <% end %> # status = 200 with timeout <%= fetch(:monit_website_check_timeout, 10) %> seconds for <%= fetch(:monit_website_check_cycles, 3) %> cycles then <%= monit_alert %> <% end %>
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
magic_recipes_two-0.0.95 | lib/generators/capistrano/magic_recipes/templates/monit/website.erb |