Timotej Lazar
d123db4e64
I have tried every possible permutation and I think this is the one. NetBox-managed IP prefixes are pushed with ansible to firewall master. The managed prefixes are added to custom IP sets defined in the app, but only NAT addresses and VPN groups can be configured for them. This way all NAT and VPN policy is (again) configured in the app. Also both NetBox-managed and user-defined networks are treated the same. Also improve^Wtweak config generation. Also templates.
41 lines
1.4 KiB
HTML
41 lines
1.4 KiB
HTML
{% extends 'base.html' %}
|
|
{% block header %}
|
|
<style>
|
|
td > input {
|
|
width: 100%;
|
|
}
|
|
</style>
|
|
{% endblock %}
|
|
|
|
{% block content %}
|
|
<p>
|
|
Urejate naslovna območja. Za statična omrežja lahko določimo naslov NAT in skupino za VPN. Za lastna območja lahko poleg tega definiramo enega ali več obsegov IP, ločenih s presledki.
|
|
|
|
<p>
|
|
NAT se izvaja na območjih, kjer je nastavljen. Uporabniki VPN imajo glede na skupine v AD enake dostope kot območja, za katera so nastavljene te skupine.
|
|
|
|
<form id="request" method="POST">
|
|
<table style="width: 100%;">
|
|
<thead>
|
|
<th>Ime<th>IP<th>IPv6<th>NAT<th>VPN
|
|
<tbody>
|
|
{% for name, data in ipsets.items() %}
|
|
<tr>
|
|
<td style="max-width: 4em;"><input name="name" value="{{ name }}" {% if not data.custom %}readonly{% endif %} />
|
|
<td style="max-width: 5em;"><input name="ip" value="{{ data.ip|join(' ') }}" {% if not data.custom %}readonly{% endif %} />
|
|
<td style="max-width: 8em;"><input name="ip6" value="{{ data.ip6|join(' ') }}" {% if not data.custom %}readonly{% endif %} />
|
|
<td style="max-width: 5em;"><input name="nat" value="{{ data.nat }}" />
|
|
<td style=""><input name="vpn" value="{{ data.vpn }}" />
|
|
{% endfor %}
|
|
<tr>
|
|
<td style="max-width: 4em;"><input name="name" />
|
|
<td style="max-width: 5em;"><input name="ip" />
|
|
<td style="max-width: 8em;"><input name="ip6" />
|
|
<td style="max-width: 5em;"><input name="nat" />
|
|
<td><input name="vpn" />
|
|
</table>
|
|
<p><button id="submit" type="submit">Shrani</button>
|
|
</form>
|
|
|
|
{% endblock %}
|