dataset/seed/systemd/templates/network
2023-07-31 15:30:32 +02:00

28 lines
668 B
Text

#RISOTTO: do not compare
{% set intnb = rougail_index %}
[Match]
{% if netwokd_interface_name_type == 'host' %}
Name=host{{ intnb }}
{% else %}
Name={{ rougail_variable }}
{% endif %}
[Link]
RequiredForOnline=yes
[Network]
LinkLocalAddressing=no
DHCP=no
{% set parent = general.network['interface_' + intnb|string] %}
{% set cidr = parent['network_eth' + intnb|string].split('/')[1] %}
Address={{ parent['ip_eth' + intnb|string] }}/{{ cidr }}
{% set gateway = parent['gateway_eth' + intnb|string] %}
{% if gateway %}
Gateway={{ gateway }}
{% endif %}
{% set dns = general.network.ip_dns %}
{% if dns %}
DNS={{ dns }}
LLMNR=no
ConfigureWithoutCarrier=yes
{% endif %}