{% extends "base.html" %} {% block content %} {% from 'include/input_macros.html' import input, checkbox, select, copy_to_clipboard %} {% if servers|length == 0 %} {% include 'include/getstarted.html' %} {% endif %}
{%- for s in servers %} {%- if serv %} {% set config_id = 'id=config_link' %} {% set compare_id = 'id=compare_link' %} {% set map_id = 'id=map_link' %} {% set stats_id = 'id=stats_link' %} {% set logs_id = 'id=logs_link' %} {% set versions_id = 'id=versions_link' %} {% endif %} {% set checker_desc = "Checker monitors " +service_desc.service + " services. If " + service_desc.service + " service changes its status, Checker will alert via Telegram, Slack, Email, Web" %} {% if service == 'nginx' %} {% set is_auto_start_enabled = s.8.0.17 %} {% set is_checker_enabled = s.8.0.19 %} {% set is_metrics_enabled = s.8.0.21 %} {% if s.5.0.1 == 'active' or s.5.0.1 == 'Up' %} {% set additional_status_class = 'div-server-head-up' %} {% else %} {% set additional_status_class = 'div-server-head-down' %} {% endif %} {% elif service == 'keepalived' %} {% set is_auto_start_enabled = s.8.0.22 %} {% set is_checker_enabled = s.8.0.23 %} {% if s.5.0.1 == 'active' %} {% set additional_status_class = 'div-server-head-up' %} {% else %} {% set additional_status_class = 'div-server-head-down' %} {% endif %} {% elif service == 'apache' %} {% set is_auto_start_enabled = s.8.0.25 %} {% set is_checker_enabled = s.8.0.26 %} {% set is_metrics_enabled = s.8.0.27 %} {% if 'Apache' in s.4.0 %} {% set additional_status_class = 'div-server-head-up' %} {% else %} {% set additional_status_class = 'div-server-head-down' %} {% endif %} {% elif service == 'haproxy' %} {% set is_auto_start_enabled = s.8.0.12 %} {% set is_checker_enabled = s.8.0.8 %} {% set is_metrics_enabled = s.8.0.9 %} {% if s.5 != False %} {% set additional_status_class = 'div-server-head-up' %} {% else %} {% set additional_status_class = 'div-server-head-down' %} {% endif %} {% endif %}
{% if not serv %} {{s.1}} {% else %} {{s.1}} {% endif %} {% if s.6|int() >= 1 %} = 1 %} class="shield green" title="Autostart is enabled"> {% else %} class="shield red" title="Autostart is enabled, but Keep alive service is not running"> {% endif %} {% endif %} {% if s.8.0.20 == 1 %} {% endif %} {% for set in docker_settings %} {% if set.server_id == s.0 and set.setting == 'dockerized' and set.value == '1' %} {% endif %} {% endfor %} {% if role <= 3 %} {% if service != 'keepalived' %} {% endif %} {% for set in restart_settings %} {% if set.server_id == s.0 and set.setting == 'restart' and set.value|int == 0 %} {% endif %} {% endfor %} {% if restart_settings|length == 0 %} {% endif %} {% if service != 'keepalived' %} {% endif %} {% endif %}
{% if s.3 is none %} No description {% else %} {{s.3}} {% endif %}
{% if service == 'nginx' or service == 'keepalived' %} Version: {{s.5.0.0}} Process_num: {{s.5.0.3}}
{% if s.5.0.1 == 'active' or s.5.0.1 == 'Up' %} Started: {% else %} Stopped: {% endif %} {{s.5.0.2}} {% elif service == 'apache' %} {% if s.4.0 is defined %} {{s.4.0.split(' ')[0].split('Server')[1]}} {{s.4.0.split(' ')[1]}} {{s.4.2}}
{{s.4.1.split(' ')[0].split('Server')[1]}} {% for i in s.4.1.split(' ')[1:5] %} {{i}}{% endfor %} {% else %} Cannot get information about Apache {% endif %} {% else %} {% if s.5.0 is defined %} {{s.5.0.0}} {{s.5.0.1}}
{{s.5.0.2}} {% else %} Cannot get information about HAProxy {% endif %} {% endif %} Last edit:
IP: {{ copy_to_clipboard(value=s.2, style='font-weight: bold') }} {% if s.7.0.0 != None %} Master for: {{ copy_to_clipboard(value=s.7.0.1, style='font-weight: bold') }} {% endif %} {% if s.9.0 == '1' %} VRRP: {% if s.9.1 == 'MASTER' or s.9.1 == 'BACKUP' or s.9.1 == 'INIT' or s.9.1 == 'FAULT' %} {{s.9.1}} {% else %} Error {% endif %} {% endif %}
{% if serv %}
{% if service == 'haproxy' %} Backends: {% elif service == 'keepalived' %} VRRP addresses: {% else %} Virtual hosts: {% endif %}
{% endif %} {% endfor %}
{% if serv %} {% for s in servers %} {% if service in ('haproxy', 'nginx', 'apache') %} {% if (service == 'haproxy' and s.8.0.9) or (service == 'nginx' and s.8.0.21) or (service == 'apache' and s.8.0.27) %}
Time range:
{% endif %} {% endif %} {% if service == 'haproxy' and s.8.0.9 %}
{% for waf_server in servers_waf %} {% if waf_server.server.ip == s.2 %}
{% endif %} {% endfor %} {% elif service == 'nginx' and s.8.0.21 %}
{% elif service == 'apache' and s.8.0.27 %}
{% endif %} {% endfor %} {% endif %} {% endblock %}