Commit f25499df authored by nanahira's avatar nanahira

optional bonds and vlans

parent 740fabe3
......@@ -17,6 +17,9 @@ iface {{link.name}} inet6 manual
{% endfor %}
# end Links
{% if bonds is defined and bonds and bonds | length > 0 %}
# Bonds
{% for bond in bonds %}
......@@ -38,6 +41,10 @@ bond-xmit-hash-policy layer2+3
{% endfor %}
# end bonds
{% endif %}
{% if vlans is defined and vlans and vlans | length > 0 %}
# Vlans
{% for vlan in vlans %}
......@@ -48,6 +55,9 @@ iface {{vlan.link}}.{{vlan.tag}} inet6 manual
{% endfor %}
# end Vlans
{% endif %}
### end non-ubuntu
{% endif %}
......@@ -80,6 +90,8 @@ pre-down {{ansible_user_dir}}/nextgen-router/scripts/{{br.name}}/pre-down.sh
{% endfor %}
# end Bridges
# PPPs
{% for ppp in ppps %}
......@@ -92,3 +104,5 @@ post-down {{ansible_user_dir}}/nextgen-router/scripts/ppp{{ppp.id}}/post-down.sh
provider ppp{{ppp.id}}
{% endfor %}
# end PPPs
......@@ -7,7 +7,7 @@ network:
dhcp4: false
dhcp6: false
{% endfor %}
{% if bonds | length > 0 %}
{% if bonds is defined and bonds and bonds | length > 0 %}
bonds:
{% for bond in bonds %}
'{{bond.name}}':
......@@ -27,7 +27,7 @@ network:
dhcp6: false
{% endfor %}
{% endif %}
{% if vlans | length > 0 %}
{% if vlans is defined and vlans and vlans | length > 0 %}
vlans:
{% for vlan in vlans %}
'{{vlan.link}}.{{vlan.tag}}':
......
......@@ -101,6 +101,7 @@
with_items:
- pap
- chap
when: pppoeUsers is defined and pppoeUsers and pppoeUsers | length > 0
- name: pppoe post scripts
become: true
template:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment