Initial commit, squashed
This commit is contained in:
commit
158e8740b8
83 changed files with 2718 additions and 0 deletions
21
roles/fabric/templates/interfaces.j2
Normal file
21
roles/fabric/templates/interfaces.j2
Normal file
|
@ -0,0 +1,21 @@
|
|||
source /etc/network/interfaces.d/*.intf
|
||||
|
||||
# Management VRF and interface.
|
||||
auto mgmt
|
||||
iface mgmt
|
||||
address 127.0.0.1/8
|
||||
address ::1/128
|
||||
vrf-table auto
|
||||
|
||||
{% for iface in interfaces | selectattr('mgmt_only') | selectattr('enabled') %}
|
||||
auto {{ iface.name }}
|
||||
iface {{ iface.name }}
|
||||
vrf mgmt
|
||||
{% for ip in iface.ip_addresses | rejectattr('address', 'match', '^fe80::.*/64$' ) %}
|
||||
address {{ ip.address }}
|
||||
{% endfor %}
|
||||
{% if iface.custom_fields.gateway %}
|
||||
gateway {{ iface.custom_fields.gateway.address | ipaddr('address') }}
|
||||
{% endif %}
|
||||
|
||||
{% endfor %}
|
Loading…
Add table
Add a link
Reference in a new issue