haproxy-wi/app/templates/ajax/service_settings.html

52 lines
2.6 KiB
HTML

{% from 'include/input_macros.html' import checkbox %}
{% set nice_service_name = {'haproxy': 'HAProxy', 'nginx': 'NGINX', 'apache': 'Apache'} %}
<table class="overview">
{% if settings %}
{% for s in settings %}
{% if s.dockerized != '' and s.setting == 'dockerized' %}
<tr>
<td class="padding20 help_cursor" style="width: 70%"
title="If you use {{ nice_service_name[service] }} inside Docker, check this. Roxy-WI is starting managing it as Docker container">{{ nice_service_name[service] }} dockerized</td>
<td>
{% set id = service + '_dockerized' %}
{% if s.value == '1' and s.setting == 'dockerized' %}
{{ checkbox(id, checked='checked', title='This service is running inside a Docker container') }}
{% else %}
{{ checkbox(id, title='This server will be used as Docker container') }}
{% endif %}
</td>
</tr>
{% endif %}
{% if s.restart != '' and s.setting == 'restart' %}
<tr>
<td class="padding20 help_cursor" style="width: 70%" title="If enabled, the restart button disabled">Disable restart</td>
<td>
{% set id = service + '_restart' %}
{% if s.value == '1' and s.setting == 'restart' %}
{{ checkbox(id, checked='checked', title='Restart option is disabled for this server') }}
{% elif s.setting == 'restart' %}
{{ checkbox(id, title='Only the reload button will be active') }}
{% endif %}
</td>
</tr>
{% endif %}
{% endfor %}
{% else %}
<tr>
<td class="padding20 help_cursor" style="width: 70%"
title="If you use {{ nice_service_name[service] }} inside Docker, check this. Roxy-WI is starting managing it as Docker container">{{ nice_service_name[service] }} dockerized</td>
<td>
{% set id = service + '_dockerized' %}
{{ checkbox(id, title='This server will be used as Docker container') }}
</td>
</tr>
<tr>
<td class="padding20 help_cursor" style="width: 70%" title="If enabled, the restart button disabled">Disable restart</td>
<td>
{% set id = service + '_restart' %}
{{ checkbox(id, title='Only the reload button will be active') }}
</td>
</tr>
{% endif %}
</table>