Commit 1f66fa6a authored by Ad Schellevis's avatar Ad Schellevis

(captiveportal, new) add rc enable/disable config template

parent faaa90bd
#rc.conf.d:/etc/rc.conf.d/captiveportal rc.conf.d:/etc/rc.conf.d/captiveportal
captiveportal.conf:/usr/local/etc/captiveportal.conf captiveportal.conf:/usr/local/etc/captiveportal.conf
lighttpd-api-dispatcher.conf:/var/etc/lighttpd-api-dispatcher.conf lighttpd-api-dispatcher.conf:/var/etc/lighttpd-api-dispatcher.conf
lighttpd-zone.conf:/var/etc/lighttpd-cp-zone-[OPNsense.captiveportal.zones.zone.%.zoneid].conf lighttpd-zone.conf:/var/etc/lighttpd-cp-zone-[OPNsense.captiveportal.zones.zone.%.zoneid].conf
{% set isEnabled=[] %}
{% if helpers.exists('OPNsense.captiveportal.zones.zone') %}
{% for cpZone in helpers.toList('OPNsense.captiveportal.zones.zone') %}
{% if cpZone.enabled|default('0') == '1' %}
{% do isEnabled.append(cpZone) %}
{% endif %}
{% endfor %}
{% endif
%}
captiveportal_enable="{% if isEnabled %}YES{% else %}NO{% endif %}"
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment