Skip to content

Instantly share code, notes, and snippets.

View maxpain's full-sized avatar
💭
Working on FASTCUP

Max Makarov maxpain

💭
Working on FASTCUP
View GitHub Profile
@maxpain
maxpain / interfaces.yaml.j2
Last active April 11, 2023 08:09
Talos Ansible Role
- interface: {{ 'bond0' if hostvars[item].bond_interfaces | length > 0 else 'eth0' }}
dhcp: false
addresses:
- {{ hostvars[item].ip }}
routes:
- network: 0.0.0.0/0
gateway: {{ hostvars[item].ip | ipaddr('1') | ipaddr('address') }}
{% if hostvars[item].bond_interfaces | length > 0 %}
bond:
interfaces: {{ hostvars[item].bond_interfaces }}