Update tinc-up.tmpl

This commit is contained in:
Manevolent 2022-12-22 10:04:15 -07:00 committed by GitHub
parent 8f7abf2af8
commit f74e2704d7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,7 +1,5 @@
#!/bin/sh
{{ if ne "true" "${enable_ipv6:-false}" }}
sysctl -w net.ipv6.conf.\$INTERFACE.disable_ipv6=1 || echo "[WARNING] IPv6 couldn't be disabled on the \$INTERFACE interface! Make sure you disable IPv6 at the host level with sysctl -w net.ipv6.conf.all.disable_ipv6=1"
{{ end }}
sysctl -w net.ipv6.conf.\$INTERFACE.disable_ipv6=1 || echo "[WARNING] IPv6 couldn't be disabled on the \$INTERFACE interface!"
{{ if len "${vip:-}" }}ifconfig "\$INTERFACE:0" ${vip}{{ end }}
{{ if len "${ip_aliases:-}" }}{{ range "$ip_aliases" | split "," }}iptables -t nat -I PREROUTING -d {{ . }} -i \$INTERFACE -j DNAT --to-destination ${tinc_peer_address}