2018-05-05 12:40:41 +00:00
{% extends "base.html" %}
2023-02-28 13:56:14 +00:00
{% block title %}{{lang.menu_links.add_proxy.title}}{% endblock %}
{% block h2 %}{{lang.menu_links.add_proxy.title}}{% endblock %}
2018-05-05 12:40:41 +00:00
{% block content %}
2019-10-25 07:18:57 +00:00
{% from 'include/input_macros.html' import input, checkbox, select %}
2020-10-16 12:33:53 +00:00
{% set balance_params = {'roundrobin':'roundrobin','source':'source','leastconn':'leastconn','first':'first',
'rdp-cookie':'rdp-cookie', 'uri':'uri', 'uri whole':'uri whole', 'static-rr': 'static-rr',
'url_param userid':'url_param userid'} %}
2024-10-02 08:51:26 +00:00
{% set checks = {'':'Choose a custom health check','tcp-check':'Check a TCP Port', 'ssl-hello-chk':'Check a SSL Port',
'httpchk':'Check a HTTP service', 'ldap-check':'Check a LDAP service', 'mysql-check':'Check a MySql Service',
'pgsql-check':'Check a PgSQL Service', 'redis-check': 'Check a Redis Service', 'smtpchk':'Check a SMTP service'} %}
2021-04-06 09:36:43 +00:00
{% set observe = {'layer7':'layer7', 'layer4': 'layer4'} %}
{% set on_error = {'mark-down':'mark-down', 'fastinter': 'fastinter', 'fail-check':'fail-check',
'sudden-death':'sudden-death'} %}
2023-04-17 15:01:01 +00:00
{% set header_res = {'http-response': 'response', 'http-request': 'request'} %}
{% set header_params = {'add-header': 'add-header', 'set-header': 'set-header', 'del-header': 'del-header'} %}
2021-03-03 13:47:42 +00:00
{% set if_values = {'1':'Host name starts with','2':'Host name ends with','3':'Path starts with','4':'Path ends with', '6': 'Src ip'} %}
2024-10-02 08:51:26 +00:00
{% set force_close = {'0':'Off','1':'Server only','2':'Force close','3':'Pretend keep alive'} %}
2020-12-15 06:34:02 +00:00
2024-08-02 09:50:02 +00:00
< script src = "/static/js/add.js" > < / script >
2024-10-02 14:10:32 +00:00
< script src = "/static/js/edit_config.js" > < / script >
2024-11-03 07:12:08 +00:00
< script src = "/static/js/le.js" > < / script >
2018-05-05 12:40:41 +00:00
< div id = "tabs" >
< ul >
2023-02-13 14:45:45 +00:00
< li > < a href = "#create" title = "{{lang.words.add|title()}} {{lang.words.proxy}}: {{lang.words.create|title()}} {{lang.words.proxy}} - Roxy-WI" > {{lang.words.create|title()}} {{lang.words.proxy}}< / a > < / li >
< li > < a href = "#listen" title = "{{lang.words.add|title()}} {{lang.words.proxy}}: {{lang.words.create|title()}} {{lang.words.listener|title()}} - Roxy-WI" > {{lang.words.listener|title()}}< / a > < / li >
< li > < a href = "#frontend" title = "{{lang.words.add|title()}} {{lang.words.proxy}}: {{lang.words.create|title()}} {{lang.words.frontend|title()}} - Roxy-WI" > {{lang.words.frontend|title()}}< / a > < / li >
< li > < a href = "#backend" title = "{{lang.words.add|title()}} {{lang.words.proxy}}: {{lang.words.create|title()}} {{lang.words.backend|title()}} - Roxy-WI" > {{lang.words.backend|title()}}< / a > < / li >
< li > < a href = "#ssl" title = "{{lang.words.add|title()}} {{lang.words.proxy}}: {{lang.words.upload|title()}} SSL {{lang.words.certs}} - Roxy-WI" > SSL {{lang.words.certs}}< / a > < / li >
< li > < a href = "#option" title = "{{lang.words.add|title()}} {{lang.words.proxy}}: {{lang.words.params|title()}} {{lang.words.templates}} - Roxy-WI" > {{lang.words.params|title()}}< / a > < / li >
< li > < a href = "#add-servers" title = "{{lang.words.add|title()}} {{lang.words.proxy}}: {{lang.words.servers|title()}} {{lang.words.templates}} - Roxy-WI" > {{lang.words.servers|title()}}< / a > < / li >
< li > < a href = "#userlist" title = "{{lang.words.add|title()}} {{lang.words.proxy}}: {{lang.words.create|title()}} {{lang.words.userlists|title()}} - Roxy-WI" > {{lang.words.userlists|title()}}< / a > < / li >
< li > < a href = "#peers" title = "{{lang.words.add|title()}} {{lang.words.proxy}}: {{lang.words.create|title()}} peers - Roxy-WI" > Peers< / a > < / li >
< li > < a href = "#lists" title = "{{lang.words.add|title()}} {{lang.words.proxy}}: {{lang.words.create|title()}} {{lang.words.and}} {{lang.words.upload}} {{lang.words.whitelists}} {{lang.words.or}} {{lang.words.blacklists}} - Roxy-WI" > {{lang.words.lists|title()}}< / a > < / li >
2023-08-03 06:56:25 +00:00
< li > < a href = "#maps" title = "{{lang.words.add|title()}} {{lang.words.proxy}}: {{lang.words.create|title()}} {{lang.words.and}} {{lang.words.upload}} {{lang.words.maps}} - Roxy-WI" > {{lang.words.maps|title()}}< / a > < / li >
2018-05-05 12:40:41 +00:00
< / ul >
2020-01-12 16:13:48 +00:00
< ul id = 'browse_histroy' > < / ul >
2024-10-02 08:51:26 +00:00
{% include 'include/add/add_proxy.html' %}
2018-05-05 12:40:41 +00:00
< div id = "listen" >
2024-10-02 08:51:26 +00:00
{% include 'include/add/listen.html' %}
2019-09-23 14:03:23 +00:00
< / div >
2021-03-03 13:47:42 +00:00
2024-10-02 08:51:26 +00:00
<!-- Second tabs -->
2021-03-03 13:47:42 +00:00
2018-05-05 12:40:41 +00:00
< div id = "frontend" >
2024-10-02 08:51:26 +00:00
{% include 'include/add/frontend.html' %}
2018-05-05 12:40:41 +00:00
< / div >
2021-03-03 13:47:42 +00:00
2024-10-02 08:51:26 +00:00
<!-- Third tabs -->
2021-03-03 13:47:42 +00:00
2018-05-05 12:40:41 +00:00
< div id = "backend" >
2024-10-02 08:51:26 +00:00
{% include 'include/add/backend.html' %}
2018-05-05 12:40:41 +00:00
< / div >
2021-03-03 13:47:42 +00:00
2018-05-05 12:40:41 +00:00
< div id = "ssl" >
2018-05-06 04:45:10 +00:00
< table >
2020-09-15 05:56:43 +00:00
< caption > < h3 > SSL< / h3 > < / caption >
2018-05-06 04:45:10 +00:00
< tr class = "overviewHead" >
2023-02-13 14:45:45 +00:00
< td class = "padding10 first-collumn" style = "width: 30%;" > {{lang.words.view|title()}} {{lang.words.cert2}}< / td >
2018-05-06 04:45:10 +00:00
< td >
2023-02-13 14:45:45 +00:00
{{lang.words.upload|title()}} {{lang.words.certs}}
2018-05-06 04:45:10 +00:00
< / td >
2021-08-26 05:44:27 +00:00
< td > < / td >
2018-05-06 04:45:10 +00:00
< / tr >
< tr >
< td class = "padding10 first-collumn" >
2024-02-04 07:28:17 +00:00
{{ select('serv5', values=g.user_params['servers'], is_servers='true') }}
2023-02-13 14:45:45 +00:00
< button id = "ssl_key_view" title = "{{lang.words.view|title()}} {{lang.words.certs}}" > {{lang.words.view|title()}}< / button >
2018-05-06 04:45:10 +00:00
< / td >
2021-08-26 05:44:27 +00:00
< td colspan = "2" style = "padding: 10px 0 10px 0;" >
< span id = "ajax-show-ssl" > < / span >
2018-05-06 04:45:10 +00:00
< / td >
< / tr >
2018-05-05 12:40:41 +00:00
< tr class = "overviewHead" >
2023-02-13 14:45:45 +00:00
< td class = "padding10 first-collumn" style = "width: 30%;" > {{lang.words.upload|title()}} SSL {{lang.words.certs}}< / td >
2018-05-05 12:40:41 +00:00
< td >
2023-02-13 14:45:45 +00:00
{{lang.words.cert_name|title()}}
2018-05-05 12:40:41 +00:00
< / td >
< td >
2023-02-13 14:45:45 +00:00
< span title = "{{lang.add_page.paste_cert_desc}}" class = "help_cursor" > {{lang.add_page.desc.paste_cert}}< / span >
2018-05-05 12:40:41 +00:00
< / td >
< / tr >
2023-04-09 13:11:16 +00:00
< tr >
2023-04-06 07:48:00 +00:00
< td class = "first-collumn padding10" valign = "top" style = "padding-top: 15px;" >
2024-02-04 07:28:17 +00:00
{{ select('serv4', values=g.user_params['servers'], is_servers='true') }}
2018-05-05 12:40:41 +00:00
< / td >
< td valign = "top" style = "padding-top: 27px;" >
2019-10-25 07:18:57 +00:00
{{ input('ssl_name') }}
2018-05-05 12:40:41 +00:00
< / td >
< td style = "padding-top: 15px; padding-bottom: 15px;" >
< textarea id = "ssl_cert" cols = "50" rows = "5" > < / textarea > < br / > < br / >
2023-02-13 14:45:45 +00:00
< button id = "ssl_key_upload" title = "{{lang.words.upload|title()}} SSL {{lang.words.cert}}" > {{lang.words.upload|title()}}< / button >
2021-03-03 13:47:42 +00:00
< / td >
2018-05-05 12:40:41 +00:00
< / tr >
< / table >
2024-11-03 07:12:08 +00:00
< table id = "le_table" >
2020-09-15 05:56:43 +00:00
< caption > < h3 > Let's Encrypt< / h3 > < / caption >
< tr class = "overviewHead" >
2023-02-13 14:45:45 +00:00
< td class = "padding10 first-collumn" > {{lang.words.server|title()}}< / td >
2024-11-03 07:12:08 +00:00
< td > {{lang.words.type|title()}}< / td >
< td > {{lang.words.domains|title()}}< / td >
< td > {{lang.words.desc|title()}}< / td >
< td > < / td >
2020-09-15 05:56:43 +00:00
< td > < / td >
< / tr >
2024-11-03 07:12:08 +00:00
< tbody id = "le_table_body" > < / tbody >
2020-09-15 05:56:43 +00:00
< / table >
2024-11-03 07:12:08 +00:00
< br / > < span class = "add-button" title = "{{lang.words.create|title()}}" onclick = "openLeDialog()" > + {{lang.words.create|title()}}< / span >
2018-05-05 12:40:41 +00:00
< div id = "ajax-ssl" > < / div >
< / div >
2019-09-17 07:18:48 +00:00
< div id = "option" >
< table class = "overview" id = "option_table" >
< tr class = "overviewHead" >
< td class = "padding10 first-collumn" > Id< / td >
2023-02-13 14:45:45 +00:00
< td class = "padding10 first-collumn" > {{lang.words.params|title()}}< / td >
2019-09-17 07:18:48 +00:00
< td > < / td >
< / tr >
{% for option in options %}
2023-03-08 13:15:15 +00:00
< tr id = "option-{{ option.id }}" class = "{{ loop.cycle('odd', 'even') }}" >
2024-02-04 07:28:17 +00:00
{% if option.groups|string() == g.user_params['group_id']|string() or group|string() == '1' %}
2019-09-17 07:18:48 +00:00
< td class = "padding10 first-collumn" >
2021-08-02 08:19:22 +00:00
{{ option.id }}
2021-03-03 13:47:42 +00:00
< / td >
2019-10-18 17:23:35 +00:00
< td class = "padding10 first-collumn" style = "width: 77%;" >
2021-08-02 08:19:22 +00:00
< input type = "text" id = "option-body-{{ option.id }}" value = "{{ option.options }}" size = "60" class = "form-control" >
2019-09-17 07:18:48 +00:00
< / td >
< td >
2023-02-13 14:45:45 +00:00
< a class = "delete" onclick = "confirmDeleteOption({{ option.id }})" title = "{{lang.words.delete|title()}} {{lang.words.param}} {{option.options}}" style = "cursor: pointer;" > < / a >
2019-09-17 07:18:48 +00:00
< / td >
{% endif %}
< / tr >
{% endfor %}
< / table >
2023-02-13 14:45:45 +00:00
< br / > < span class = "add-button" title = "{{lang.words.add|title()}} {{lang.words.param}}" id = "add-option-button" > + {{lang.words.add|title()}}< / span >
2019-09-17 07:18:48 +00:00
< br / > < br / >
< table class = "overview" id = "option-add-table" style = "display: none;" >
< tr class = "overviewHead" >
< td class = "padding10 first-collumn" > < / td >
2023-02-13 14:45:45 +00:00
< td > {{lang.words.param|title()}}< / td >
2019-09-17 07:18:48 +00:00
< td > < / td >
< / tr >
< tr >
< td class = "padding10 first-collumn" >
2023-02-13 14:45:45 +00:00
{{lang.words.enter|title()}} {{lang.words.w_an}} {{lang.words.param}}:
2019-09-17 07:18:48 +00:00
< / td >
2019-10-18 17:23:35 +00:00
< td style = "width: 77%;" >
2019-10-25 07:18:57 +00:00
{{ input('new-option', size='60') }}
2019-09-17 07:18:48 +00:00
< / td >
< td >
2023-02-13 14:45:45 +00:00
< span class = "add-admin" id = "add-option-new" title = "{{lang.words.add|title()}} {{lang.words.new}} {{lang.words.param}}" style = "cursor: pointer;" > < / span >
2019-09-17 07:18:48 +00:00
< / td >
< / tr >
< / table >
2019-10-09 06:35:35 +00:00
< div id = "ajax-option" > < / div >
2021-09-07 08:18:27 +00:00
< div class = "add-note alert addName alert-info" style = "width: inherit; margin-right: 15px;" >
2023-02-13 14:45:45 +00:00
{{lang.add_page.desc.options}}
2019-09-20 06:42:19 +00:00
< / div >
2019-09-17 07:18:48 +00:00
< / div >
2021-03-03 13:47:42 +00:00
2019-10-09 06:35:35 +00:00
< div id = "add-servers" >
< table class = "overview" id = "servers_table" >
< tr class = "overviewHead" >
2023-02-13 14:45:45 +00:00
< td class = "padding10 first-collumn" > {{lang.words.server|title()}}< / td >
< td class = "padding10 first-collumn" > {{lang.words.desc|title()}}< / td >
2019-10-09 06:35:35 +00:00
< td > < / td >
< / tr >
{% for s in saved_servers %}
2021-08-02 08:19:22 +00:00
< tr id = "servers-saved-{{ s.id }}" class = "{{ loop.cycle('odd', 'even') }}" >
2024-02-04 07:28:17 +00:00
{% if s.groups|string() == g.user_params['group_id']|string() or group|string() == '1' %}
2019-10-09 06:35:35 +00:00
< td class = "padding10 first-collumn" >
2021-08-02 08:19:22 +00:00
< input type = "text" id = "servers-ip-{{ s.id }}" value = "{{ s.server }}" size = "15" class = "form-control" >
2021-03-03 13:47:42 +00:00
< / td >
2019-10-18 17:23:35 +00:00
< td class = "padding10 first-collumn" style = "width: 77%;" >
2021-08-02 08:19:22 +00:00
< input type = "text" id = "servers-desc-{{ s.id }}" value = "{{ s.description }}" size = "50" class = "form-control" >
2019-10-09 06:35:35 +00:00
< / td >
< td >
2023-02-13 14:45:45 +00:00
< a class = "delete" onclick = "confirmDeleteSavedServer({{ s.id }})" title = "{{lang.words.delete|title()}} {{lang.words.server}} {{s.server}}" style = "cursor: pointer;" > < / a >
2019-10-09 06:35:35 +00:00
< / td >
{% endif %}
< / tr >
{% endfor %}
< / table >
2023-02-13 14:45:45 +00:00
< br / > < span class = "add-button" title = "{{lang.words.add|title()}} {{lang.words.server}}" id = "add-saved-server-button" > + {{lang.words.add|title()}}< / span >
2019-10-09 06:35:35 +00:00
< br / > < br / >
< table class = "overview" id = "saved-server-add-table" style = "display: none;" >
< tr class = "overviewHead" >
2023-02-13 14:45:45 +00:00
< td class = "padding10 first-collumn" > {{lang.words.server|title()}}< / td >
< td > {{lang.words.desc|title()}}< / td >
2019-10-09 06:35:35 +00:00
< td > < / td >
< / tr >
< tr >
< td class = "padding10 first-collumn" >
2019-10-25 07:18:57 +00:00
{{ input('new-saved-servers', size='15') }}
2019-10-09 06:35:35 +00:00
< / td >
2019-10-18 17:23:35 +00:00
< td style = "width: 77%;" >
2019-10-25 07:18:57 +00:00
{{ input('new-saved-servers-description', size='50') }}
2019-10-09 06:35:35 +00:00
< / td >
< td >
2023-02-13 14:45:45 +00:00
< span class = "add-admin" id = "add-saved-server-new" title = "{{lang.words.add|title()}} {{lang.words.new|title()}} {{lang.words.server|title()}}" style = "cursor: pointer;" > < / span >
2019-10-09 06:35:35 +00:00
< / td >
< / tr >
< / table >
< div id = "ajax-servers" > < / div >
2021-09-07 08:18:27 +00:00
< div class = "add-note alert addName alert-info" style = "width: inherit; margin-right: 15px;" >
2023-02-13 14:45:45 +00:00
{{lang.add_page.desc.servers}}
2019-10-09 06:35:35 +00:00
< / div >
< / div >
2019-10-18 17:23:35 +00:00
< div id = "userlist" >
2024-10-02 08:51:26 +00:00
{% include 'include/add/userlist.html' %}
2019-10-18 17:23:35 +00:00
< div class = "add-note addName alert-info" style = "width: inherit; margin-right: 15px;" >
2023-02-13 14:45:45 +00:00
{{lang.add_page.desc.userlist}}
2021-03-03 13:47:42 +00:00
< / div >
2021-09-07 08:18:27 +00:00
< div class = "add-note alert addName alert-info" style = "width: inherit; margin-right: 15px;" >
2023-02-13 14:45:45 +00:00
{{lang.words.read|title()}}
< a href = "https://roxy-wi.org/description/userlist" title = "How to use userlists" target = "_blank" >
< b > {{lang.words.here}}< / b >
2019-10-18 17:23:35 +00:00
< / a >
2023-02-13 14:45:45 +00:00
{{lang.phrases.howto_user}} {{lang.words.userlists}}
2019-10-18 17:23:35 +00:00
< / div >
2021-03-03 13:47:42 +00:00
< / div >
2021-06-02 07:28:07 +00:00
< div id = "peers" >
2024-10-02 08:51:26 +00:00
{% include 'include/add/peers.html' %}
2021-06-02 07:28:07 +00:00
< div class = "alert addName alert-info" style = "width: inherit; margin-right: 15px;" >
2023-02-13 14:45:45 +00:00
{{lang.add_page.desc.peers_master}}
2021-06-02 07:28:07 +00:00
< / div >
< div class = "alert addName alert-info" style = "width: inherit; margin-right: 15px;" >
2023-02-13 14:45:45 +00:00
{{lang.add_page.desc.peers_slave}}
2021-06-02 07:28:07 +00:00
< / div >
2021-09-07 08:18:27 +00:00
< div class = "add-note alert addName alert-info" style = "width: inherit; margin-right: 15px;" >
2023-02-13 14:45:45 +00:00
{{lang.words.read|title()}}
< a href = "https://roxy-wi.org/howto/peers" title = "How to use peers" target = "_blank" >
< b > {{lang.words.here}}< / b >
2021-06-02 07:28:07 +00:00
< / a >
2023-02-13 14:45:45 +00:00
{{lang.phrases.howto_user}} peers
2021-06-02 07:28:07 +00:00
< / div >
< / div >
2020-01-12 16:13:48 +00:00
< div id = "lists" >
< table class = "overview" >
< tr class = "overviewHead" >
2023-02-13 14:45:45 +00:00
< th class = "padding10 first-collumn" > {{lang.words.new|title()}} {{lang.words.blacklist}}< / th >
< th > {{lang.words.server|title()}} {{lang.words.for}} {{lang.words.uploading}}< / th >
< th > {{lang.words.existing|title()}} {{lang.words.blacklists}}< / th >
2020-01-12 16:13:48 +00:00
< / tr >
< tr >
2020-11-02 17:01:08 +00:00
< td class = "padding10 first-collumn" style = "width: 25%;" >
2023-02-13 14:45:45 +00:00
{{lang.words.name|title()}}: {{ input('new_blacklist_name') }}
< button onclick = "createList('black')" > {{lang.words.create|title()}}< / button >
2020-11-02 17:01:08 +00:00
< / td >
2023-04-09 13:11:16 +00:00
< td class = "first-collumn" >
2024-02-04 07:28:17 +00:00
{{ select('serv-black-list', values=g.user_params['servers'], is_servers='true') }}
2020-04-23 21:11:37 +00:00
< / td >
2021-08-26 05:44:27 +00:00
< td style = "width: 30%; padding: 10px 0 10px 0;" >
2020-01-12 16:13:48 +00:00
{% for list in black_lists %}
2023-08-05 06:25:59 +00:00
< span class = "list_of_lists list_blacklists" >
2023-08-03 06:56:25 +00:00
< a onclick = "editList('{{ list }}', 'black')" title = "{{lang.words.edit|title()}} {{lang.words.the}} {{ list }} {{lang.words.list}}" > {{ list }}< / a >
2021-08-26 05:44:27 +00:00
< / span >
2020-01-12 16:13:48 +00:00
{% endfor %}
< / td >
2021-03-03 13:47:42 +00:00
2020-04-23 21:11:37 +00:00
< / tr >
{{ input('group', value=group, type='hidden') }}
< / table >
< table >
< tr class = "overviewHead" >
2023-02-13 14:45:45 +00:00
< th class = "padding10 first-collumn" > {{lang.words.new|title()}} {{lang.words.whitelist}}< / th >
< th > {{lang.words.server|title()}} {{lang.words.for}} {{lang.words.uploading}}< / th >
< th > {{lang.words.existing|title()}} {{lang.words.whitelists}}< / th >
2020-04-23 21:11:37 +00:00
< / tr >
< tr >
2020-11-02 17:01:08 +00:00
< td class = "padding10 first-collumn" style = "width: 25%;" >
2023-02-13 14:45:45 +00:00
{{lang.words.name|title()}}: {{ input('new_whitelist_name') }}
< button onclick = "createList('white')" > {{lang.words.create|title()}}< / button >
2020-11-02 17:01:08 +00:00
< / td >
2023-04-09 13:11:16 +00:00
< td class = "first-collumn" >
2024-02-04 07:28:17 +00:00
{{ select('serv-white-list', values=g.user_params['servers'], is_servers='true') }}
2020-04-23 21:11:37 +00:00
< / td >
2021-08-26 05:44:27 +00:00
< td style = "width: 30%; padding: 10px 0 10px 0;" >
2020-01-12 16:13:48 +00:00
{% for list in white_lists %}
2023-08-05 06:25:59 +00:00
< span class = "list_of_lists list_whitelists" >
2023-02-13 14:45:45 +00:00
< a onclick = "editList('{{ list }}', 'white')" title = "{{lang.words.edit|title()}} {{lang.words.the}} {{ list }} {{lang.words.list}}" > {{ list }}< / a >
2021-08-26 05:44:27 +00:00
< / span >
2020-01-12 16:13:48 +00:00
{% endfor %}
< / td >
< / tr >
< / table >
2020-04-23 21:11:37 +00:00
< div id = "ajax" > < / div >
2021-09-07 08:18:27 +00:00
< div class = "add-note alert addName alert-info" style = "width: inherit; margin-right: 15px;" >
2023-02-13 14:45:45 +00:00
{{lang.add_page.desc.lists_howto}}
< a href = "https://roxy-wi.org/howto/blacklist" title = "How to create and manage blacklist" target = "_blank" > {{lang.words.article}}< / a >
2020-01-12 16:13:48 +00:00
< / div >
2023-08-03 06:56:25 +00:00
< div id = "dialog-confirm-cert-edit" title = "{{lang.words.view|title()}} {{lang.words.cert}} " style = "display: none;" >
2023-02-13 14:45:45 +00:00
< span > < b > {{lang.words.note|title()}}:< / b > {{lang.add_page.desc.lists_new_line}}< / span >
2020-01-12 16:13:48 +00:00
< textarea id = "edit_lists" style = "width: 100%" rows = 20 > < / textarea >
2021-03-03 13:47:42 +00:00
< / div >
2020-01-12 16:13:48 +00:00
< / div >
2023-08-03 06:56:25 +00:00
< div id = "maps" >
< table class = "overview" >
< tr class = "overviewHead" >
< th class = "padding10 first-collumn" > {{lang.words.new|title()}} {{lang.words.map}}< / th >
< th > {{lang.words.server|title()}} {{lang.words.for}} {{lang.words.uploading}}< / th >
< th > {{lang.words.existing|title()}} {{lang.words.maps}}< / th >
< / tr >
< tr >
< td class = "padding10 first-collumn" style = "width: 25%;" >
{{lang.words.name|title()}}: {{ input('new_map_name') }}
< button onclick = "createMap()" > {{lang.words.create|title()}}< / button >
< / td >
< td class = "first-collumn" >
2024-02-04 07:28:17 +00:00
{{ select('serv-map', values=g.user_params['servers'], is_servers='true') }}
2023-08-03 06:56:25 +00:00
< / td >
< td style = "width: 30%; padding: 10px 0 10px 0;" >
{% for map in maps %}
2023-08-05 06:25:59 +00:00
< span class = "list_of_lists list_maps" >
2023-08-03 06:56:25 +00:00
< a onclick = "editMap('{{ map }}')" title = "{{lang.words.edit|title()}} {{lang.words.the}} {{ map }} {{lang.words.map}}" > {{ map }}< / a >
< / span >
{% endfor %}
< / td >
< / tr >
{{ input('group', value=group, type='hidden') }}
< / table >
< div id = "ajax-maps" > < / div >
< div class = "add-note alert addName alert-info" style = "width: inherit; margin-right: 15px;" >
{{lang.add_page.desc.lists_howto}}
< a href = "https://www.haproxy.com/blog/introduction-to-haproxy-maps" title = "Introduction to HAProxy Maps" target = "_blank" > {{lang.words.article}}< / a >
< / div >
< div id = "dialog-confirm-map-edit" title = "{{lang.words.view|title()}} {{lang.words.map}} " style = "display: none;" >
< span > < b > {{lang.words.note|title()}}:< / b > {{lang.add_page.desc.lists_new_line}}< / span >
< textarea id = "edit_map" style = "width: 100%" rows = 20 > < / textarea >
< / div >
< / div >
2019-10-25 07:18:57 +00:00
{% include 'include/del_confirm.html' %}
< div id = "dialog-confirm-cert" title = "View certificate " style = "display: none;" >
2020-12-15 06:34:02 +00:00
< pre id = "dialog-confirm-body" > < / pre >
2018-07-13 04:28:21 +00:00
< / div >
2024-02-04 07:28:17 +00:00
< input type = "hidden" id = "group_id" value = "{{ g.user_params['group_id']|string() }}" >
2019-09-20 06:42:19 +00:00
< / div >
< / div >
2018-05-12 15:49:24 +00:00
< script >
2019-10-25 07:18:57 +00:00
$( function() {
$( ".force_close" ).selectmenu({
width: 180
});
2020-01-11 21:16:27 +00:00
if (window.matchMedia('(max-width: 1280px)').matches || window.matchMedia('(max-width: 1024px)').matches || window.matchMedia('(max-width: 667px)').matches) {
$( "select" ).selectmenu({
width: 150
});
}
2018-05-12 15:49:24 +00:00
});
2020-10-16 12:33:53 +00:00
var serv_ports = $('.send_proxy');
for (var i = 0; i < = serv_ports.length; i++) {
var uniqId = makeid(3);
2022-11-20 07:48:15 +00:00
$(serv_ports[i]).append('< label for = "' + uniqId + '" class = "send_proxy_label" title = "Set send-proxy for this server" data-help = "The Send-proxy parameter enforces the use of the PROXY protocol over any connection established to this server. The PROXY protocol informs the other end about the layer 3/4 addresses of the incoming connection so that it can know the client\'s address or the public address it accessed to, whatever the upper-layer protocol." > send-proxy< / label > < input type = "checkbox" name = "send_proxy" value = "1" id = "' + uniqId + '" > ');
2020-10-16 12:33:53 +00:00
var uniqId = makeid(3);
2022-11-20 07:48:15 +00:00
$(serv_ports[i]).append('< label for = "' + uniqId + '" class = "send_proxy_label" title = "Set this server as backup server" data-help = "When all servers in a farm are down , we want to redirect traffic to a backup server which delivers either sorry pages or a degraded mode of the application . \ n ' +
'This can be done easily in HAProxy by adding the keyword backup on the server line. If multiple backup servers are configured, only the first active one is used.">backup< / label > < input type = "checkbox" name = "backup" value = "1" id = "' + uniqId + '" > ');
2020-10-16 12:33:53 +00:00
}
2018-05-12 15:49:24 +00:00
< / script >
2024-11-03 07:12:08 +00:00
< div id = "le-add-table" style = "display: none;" >
< table class = "overview" id = "group-add-table-overview" title = "{{lang.words.add|title()}} {{lang.words.w_a}} {{lang.words.new3}} {{lang.words.group2}}" >
{% include 'include/tr_validate_tips.html' %}
< tr >
< td class = "padding20 first-collumn" >
{{ lang.words.server|title() }}
< / td >
< td >
{{ select('new-le-server_id', values=g.user_params['servers'], is_servers='true', by_id=1) }}
< / td >
< / tr >
< tr >
< td class = "padding20 first-collumn" >
{{ lang.words.type|title() }}
< / td >
< td >
< select id = "new-le-type" >
< option value = "standalone" > Stand alone< / option >
< option value = "route53" > Route 53< / option >
< option value = "cloudflare" > CloudFlare< / option >
< option value = "digitalocean" > DigitalOcean< / option >
< option value = "linode" > Linode< / option >
< / select >
< / td >
< / tr >
< tr >
< td class = "padding20 first-collumn" >
{{ lang.words.domains|title() }}
< / td >
< td >
{{ input('new-le-domain') }}
< div class = "tooltip tooltipTop" > {{ lang.add_page.desc.comma_separated }}< / div >
< / td >
< / tr >
< tr class = "le-standalone" >
< td class = "padding20 first-collumn" >
{{ lang.words.email|title() }}
< / td >
< td >
{{ input('new-le-email') }}
< / td >
< / tr >
< tr class = "le-dns" style = "display: none;" >
< td class = "padding20 first-collumn" >
{{ lang.words.token|title() }}
< / td >
< td >
{{ input('new-le-token') }}
< / td >
< / tr >
< tr class = "le-aws" style = "display: none;" >
< td class = "padding20 first-collumn" >
Access key ID
< / td >
< td >
{{ input('new-le-access_key_id') }}
< / td >
< / tr >
< tr class = "le-aws" style = "display: none;" >
< td class = "padding20 first-collumn" >
Secret access key
< / td >
< td >
{{ input('new-le-secret_access_key') }}
< / td >
< / tr >
< tr >
< td class = "padding20 first-collumn" >
{{ lang.words.desc|title() }}
< / td >
< td >
{{ input('new-le-description') }}
< / td >
< / tr >
< / table >
< / div >
2019-12-04 13:38:07 +00:00
{% endblock %}