summaryrefslogtreecommitdiff
path: root/roles/vm/guest/network/templates/interfaces/overlay.j2
diff options
context:
space:
mode:
Diffstat (limited to 'roles/vm/guest/network/templates/interfaces/overlay.j2')
-rw-r--r--roles/vm/guest/network/templates/interfaces/overlay.j24
1 files changed, 2 insertions, 2 deletions
diff --git a/roles/vm/guest/network/templates/interfaces/overlay.j2 b/roles/vm/guest/network/templates/interfaces/overlay.j2
index 0524c5df..b2ef11a9 100644
--- a/roles/vm/guest/network/templates/interfaces/overlay.j2
+++ b/roles/vm/guest/network/templates/interfaces/overlay.j2
@@ -2,13 +2,13 @@
netmask {{ interface.address | ipaddr('netmask') }}
up /bin/ip addr add dev $IFACE {{ interface.overlay }}/32
{% for route in interface.static_routes | default([]) %}
- up /bin/ip route add {{ route.destination }} via {{ route.gateway }}{% if 'source' in route %} src {{ route.source }}{% endif %}
+ up /bin/ip route add {{ route.destination }} via {{ route.gateway }}{% if 'source' in route %} src {{ route.source }}{% endif %}{{ '' }}
{% endfor %}
{% if 'gateway' in interface %}
up /bin/ip route add default via {{ interface.gateway }} src {{ interface.overlay }}
down /bin/ip route del default via {{ interface.gateway }} src {{ interface.overlay }}
{% endif %}
{% for route in interface.static_routes | default([]) | reverse %}
- down /bin/ip route del {{ route.destination }} via {{ route.gateway }}{% if 'source' in route %} src {{ route.source }}{% endif %}
+ down /bin/ip route del {{ route.destination }} via {{ route.gateway }}{% if 'source' in route %} src {{ route.source }}{% endif %}{{ '' }}
{% endfor %}
down /bin/ip addr del dev $IFACE {{ interface.overlay }}/32