mirror of
https://github.com/opnsense/plugins.git
synced 2026-05-28 04:34:15 -04:00
Add run as root option
This commit is contained in:
parent
4ef2cb7211
commit
2e641cfa4e
3 changed files with 15 additions and 1 deletions
|
|
@ -17,6 +17,13 @@
|
|||
<label>NOTE: Define global parameters for the HAProxy service. They cannot be overriden.</label>
|
||||
<type>info</type>
|
||||
</field>
|
||||
<field>
|
||||
<id>haproxy.general.tuning.root</id>
|
||||
<label>Run as root</label>
|
||||
<type>checkbox</type>
|
||||
<help><![CDATA[Enable or disable HAProxy running as root.<br/><div class="text-info"><b>NOTE:</b> Enabling root could be a security issue but it's required by some feature.</div>]]></help>
|
||||
<advanced>true</advanced>
|
||||
</field>
|
||||
<field>
|
||||
<id>haproxy.general.tuning.chroot</id>
|
||||
<label>Secure mode (chroot)</label>
|
||||
|
|
|
|||
|
|
@ -10,6 +10,10 @@
|
|||
<Required>Y</Required>
|
||||
</enabled>
|
||||
<tuning>
|
||||
<root type="BooleanField">
|
||||
<default>0</default>
|
||||
<Required>Y</Required>
|
||||
</root>
|
||||
<chroot type="BooleanField">
|
||||
<default>0</default>
|
||||
<Required>Y</Required>
|
||||
|
|
|
|||
|
|
@ -441,7 +441,10 @@
|
|||
{# ############################### #}
|
||||
|
||||
global
|
||||
#uid 80
|
||||
{% if OPNsense.HAProxy.general.tuning.root != "1" %}
|
||||
# NOTE: Could be a security issue, but required for some feature.
|
||||
uid 80
|
||||
{% endif %}
|
||||
gid 80
|
||||
{% if OPNsense.HAProxy.general.tuning.chroot == "1" %}
|
||||
# NOTE: chroot prevents (most) local logging, you need to enable remote
|
||||
|
|
|
|||
Loading…
Reference in a new issue