mirror of https://github.com/Aidaho12/haproxy-wi
parent
c1c5d13131
commit
a4407a1362
|
@ -242,8 +242,7 @@ def page_for_admin(**kwargs):
|
||||||
give_level = 1
|
give_level = 1
|
||||||
|
|
||||||
if not is_admin(level=give_level):
|
if not is_admin(level=give_level):
|
||||||
print('<center><h3 style="color: red">How did you get here?! O_o You do not have need permissions</h>')
|
print('<meta http-equiv="refresh" content="0; url=/">')
|
||||||
print('<meta http-equiv="refresh" content="5; url=/">')
|
|
||||||
import sys
|
import sys
|
||||||
sys.exit()
|
sys.exit()
|
||||||
|
|
||||||
|
@ -420,7 +419,7 @@ def get_section_from_config(config, section):
|
||||||
return_config = ""
|
return_config = ""
|
||||||
with open(config, 'r') as f:
|
with open(config, 'r') as f:
|
||||||
for index, line in enumerate(f):
|
for index, line in enumerate(f):
|
||||||
if line.startswith(section):
|
if line.startswith(section + '\n'):
|
||||||
start_line = index
|
start_line = index
|
||||||
return_config += line
|
return_config += line
|
||||||
record = True
|
record = True
|
||||||
|
|
|
@ -282,7 +282,7 @@
|
||||||
</div>
|
</div>
|
||||||
{% if configver %}
|
{% if configver %}
|
||||||
<br>
|
<br>
|
||||||
<div style="text-align: center;">
|
<center>
|
||||||
{% if role <= 3 %}
|
{% if role <= 3 %}
|
||||||
{% if not is_serv_protected or role <= 2 %}
|
{% if not is_serv_protected or role <= 2 %}
|
||||||
<form action="versions.py?service={{service}}" method="post">
|
<form action="versions.py?service={{service}}" method="post">
|
||||||
|
@ -298,5 +298,5 @@
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
<div class="alert alert-info"><b>Note:</b> If you reconfigure Master server, Slave will reconfigured automatically</div>
|
<div class="alert alert-info"><b>Note:</b> If you reconfigure Master server, Slave will reconfigured automatically</div>
|
||||||
</div>
|
</center>
|
||||||
{% endif %}
|
{% endif %}
|
Loading…
Reference in New Issue