Consolidate NAT and VPN settings into IP sets

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.
This commit is contained in:
Timotej Lazar 2024-04-30 15:13:50 +02:00
parent cac7658566
commit d123db4e64
10 changed files with 154 additions and 162 deletions

View file

@ -54,9 +54,6 @@ def create_app(test_config=None):
from . import ipsets
app.register_blueprint(ipsets.blueprint, url_prefix='/ipsets')
from . import nat
app.register_blueprint(nat.blueprint, url_prefix='/nat')
from . import rules
app.register_blueprint(rules.blueprint, url_prefix='/rules')