Before we relied on the IP being first in the interfaces file, which is less than optimal. Now we use nftables to ensure the correct source IP is set only for the (fwmarked) wireguard traffic. Also remove iface hints from interfaces configuration as they are not needed with ifupdown-ng.
		
			
				
	
	
		
			9 lines
		
	
	
	
		
			239 B
		
	
	
	
		
			Django/Jinja
		
	
	
	
	
	
			
		
		
	
	
			9 lines
		
	
	
	
		
			239 B
		
	
	
	
		
			Django/Jinja
		
	
	
	
	
	
| {% set addrs = interfaces | selectattr('name', '==', 'lo') | map(attribute='ip_addresses') | first -%}
 | |
| 
 | |
| auto lo
 | |
| iface lo
 | |
| {% for address in addrs %}
 | |
|     address {{ address.address }}
 | |
| {% endfor %}
 | |
| 
 | |
| source-directory /etc/network/interfaces.d
 |