diff --git a/roles/strongswan/templates/mobileconfig.j2 b/roles/strongswan/templates/mobileconfig.j2 index 3a6b6e32..77dc4e96 100644 --- a/roles/strongswan/templates/mobileconfig.j2 +++ b/roles/strongswan/templates/mobileconfig.j2 @@ -1,3 +1,4 @@ +#jinja2:lstrip_blocks: True @@ -7,7 +8,7 @@ IKEv2 -{%- if algo_ondemand_wifi or algo_ondemand_cellular %} +{% if algo_ondemand_wifi or algo_ondemand_cellular %} OnDemandEnabled 1 OnDemandRules @@ -21,19 +22,19 @@ WiFi SSIDMatch - {%- for network_name in WIFI_EXCLUDE_LIST %} + {% for network_name in WIFI_EXCLUDE_LIST %} {{ network_name|e }} - {%- endfor %} + {% endfor %} - {%- endif %} + {% endif %} Action - {%- if algo_ondemand_wifi %} + {% if algo_ondemand_wifi %} Connect - {%- else %} + {% else %} Disconnect - {%- endif %} + {% endif %} InterfaceTypeMatch WiFi URLStringProbe @@ -41,11 +42,11 @@ Action - {%- if algo_ondemand_cellular %} + {% if algo_ondemand_cellular %} Connect - {%- else %} + {% else %} Disconnect - {%- endif %} + {% endif %} InterfaceTypeMatch Cellular URLStringProbe @@ -56,7 +57,7 @@ Disconnect -{%- endif %} +{% endif %} AuthenticationMethod Certificate ChildSecurityAssociationParameters