19 lines
712 B
Django/Jinja
19 lines
712 B
Django/Jinja
<Request>
|
|
<Login>
|
|
<Username>{{ sophos_api_username }}</Username>
|
|
<Password>{{ sophos_api_password }}</Password>
|
|
</Login>
|
|
<Set operation="{% if item.name in existing_vlans %}update{% else %}add{% endif %}">
|
|
<VLANInterface>
|
|
<Name>{{ item.name }}</Name>
|
|
<Description>{{ item.description | default('') }}</Description>
|
|
<VLANID>{{ item.vlan_id }}</VLANID>
|
|
<ParentInterface>{{ item.parent_interface }}</ParentInterface>
|
|
<Zone>{{ item.zone }}</Zone>
|
|
<IPAddress>{{ item.ip_address }}</IPAddress>
|
|
<Netmask>{{ item.netmask }}</Netmask>
|
|
<Status>{{ 'Enable' if item.enabled | default(true) else 'Disable' }}</Status>
|
|
</VLANInterface>
|
|
</Set>
|
|
</Request>
|