Update tinc/tinc-up.tmpl, tinc/tinc-down.tmpl, Dockerfile.tinc files
This commit is contained in:
parent
45ca87fb49
commit
1be8caa32e
@ -1,7 +1,7 @@
|
|||||||
FROM alpine:latest
|
FROM alpine:latest
|
||||||
MAINTAINER Team Lixo <lixonet@team.lixo>
|
MAINTAINER Team Lixo <lixonet@team.lixo>
|
||||||
|
|
||||||
RUN apk add tinc
|
RUN apk add tinc iptables
|
||||||
|
|
||||||
EXPOSE 9993/tcp 655/udp
|
EXPOSE 9993/tcp 655/udp
|
||||||
VOLUME /etc/tinc
|
VOLUME /etc/tinc
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
# Disable IPv4 kernel routing/forwarding for this network
|
# Disable IPv4 kernel routing/forwarding for this network
|
||||||
/sbin/iptables -D FORWARD -o \$INTERFACE -d ${network_address}/${global_prefix:-16} -j ACCEPT
|
iptables -D FORWARD -o \$INTERFACE -d ${network_address}/${global_prefix:-16} -j ACCEPT
|
||||||
{{ if len "${bgp_routes:-}" }}{{ range "$bgp_routes" | split "," }}/sbin/iptables -D FORWARD -o ${internal_interface:-eth0} -d {{.}} -j ACCEPT
|
{{ if len "${bgp_routes:-}" }}{{ range "$bgp_routes" | split "," }}iptables -D FORWARD -o ${internal_interface:-eth0} -d {{.}} -j ACCEPT
|
||||||
{{ end }}{{ end }}
|
{{ end }}{{ end }}
|
||||||
|
@ -2,6 +2,6 @@
|
|||||||
ifconfig \$INTERFACE ${tinc_peer_address} netmask ${netmask:-255.255.255.0}
|
ifconfig \$INTERFACE ${tinc_peer_address} netmask ${netmask:-255.255.255.0}
|
||||||
|
|
||||||
# Enable IPv4 kernel routing/forwarding for this network
|
# Enable IPv4 kernel routing/forwarding for this network
|
||||||
/sbin/iptables -A FORWARD -o \$INTERFACE -d ${network_address}/${global_prefix:-16} -j ACCEPT
|
iptables -A FORWARD -o \$INTERFACE -d ${network_address}/${global_prefix:-16} -j ACCEPT
|
||||||
{{ if len "${bgp_routes:-}" }}{{ range "$bgp_routes" | split "," }}/sbin/iptables -A FORWARD -o ${internal_interface:-eth0} -d {{.}} -j ACCEPT
|
{{ if len "${bgp_routes:-}" }}{{ range "$bgp_routes" | split "," }}iptables -A FORWARD -o ${internal_interface:-eth0} -d {{.}} -j ACCEPT
|
||||||
{{ end }}{{ end }}
|
{{ end }}{{ end }}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user