D7net
Home
Console
Upload
information
Create File
Create Folder
About
Tools
:
/
opt
/
saltstack
/
salt
/
lib
/
python3.10
/
site-packages
/
salt
/
templates
/
debian_ip
/
Filename :
route_eth.jinja
back
Copy
#!/bin/sh # {{route_type}} test "${IFACE}" = "{{iface}}" || exit 0 {% for route in routes %}{% if route.name %}# {{route.name}} {%endif%}ip route {{route_type}} {% if route.ipaddr %}{{route.ipaddr}}{%endif%}{% if route.netmask %}/{{route.netmask}}{%endif%} {% if route.gateway %}via {{route.gateway}}{%endif%} dev {{iface}}{% if route.metric %} metric {{route.metric}}{%endif%} {% endfor %}