now with ipv6!
parent
d622f9218c
commit
db83e0fb8e
|
@ -19,10 +19,15 @@ config dhcp 'lan'
|
|||
option leasetime '12h'
|
||||
option dhcpv6 'server'
|
||||
option ra 'server'
|
||||
option ndp 'hybrid'
|
||||
|
||||
config dhcp 'wan'
|
||||
option interface 'wan'
|
||||
option ignore '1'
|
||||
option ignore '1'
|
||||
option interface 'wan'
|
||||
option dhcpv6 'relay'
|
||||
option ra 'relay'
|
||||
option ndp 'relay'
|
||||
option master '1'
|
||||
|
||||
config odhcpd 'odhcpd'
|
||||
option maindhcp '0'
|
||||
|
|
|
@ -1,3 +1,6 @@
|
|||
config globals globals
|
||||
option 'ula_prefix' "${LAN6_SUBNET}"
|
||||
|
||||
config 'interface' 'loopback'
|
||||
option 'ifname' 'lo'
|
||||
option 'proto' 'static'
|
||||
|
@ -11,7 +14,12 @@ config 'interface' 'lan'
|
|||
option 'ipaddr' "${LAN_ADDR}"
|
||||
option 'gateway' "${LAN_GW}"
|
||||
option 'netmask' "${LAN_NETMASK}"
|
||||
option 'ip6assign' 64
|
||||
|
||||
config 'interface' 'wan'
|
||||
option 'ifname' 'eth1'
|
||||
option 'proto' 'dhcp'
|
||||
option 'proto' 'dhcp'
|
||||
|
||||
config 'interface' 'wan6'
|
||||
option 'ifname' 'eth1'
|
||||
option 'proto' 'dhcpv6'
|
|
@ -16,6 +16,7 @@ UPSTREAM_DNS_SERVER=192.168.12.2
|
|||
LAN_NAME=openwrt-lan
|
||||
LAN_DOMAIN=home
|
||||
LAN_SUBNET=192.168.16.0/24
|
||||
LAN6_SUBNET=fd99:1234::/48
|
||||
LAN_ADDR=192.168.16.2
|
||||
LAN_HOST=192.168.16.1
|
||||
# openwrt doesn't accept CIDR notation; must match LAN_SUBNET
|
||||
|
|
3
run.sh
3
run.sh
|
@ -92,8 +92,9 @@ function _create_or_start_container() {
|
|||
--cap-add NET_RAW \
|
||||
--hostname openwrt \
|
||||
--ip $LAN_ADDR \
|
||||
--sysctl net.ipv4.conf.default.arp_ignore=1 \
|
||||
--sysctl net.netfilter.nf_conntrack_acct=1 \
|
||||
--sysctl net.ipv6.conf.all.disable_ipv6=0 \
|
||||
--sysctl net.ipv6.conf.all.forwarding=1 \
|
||||
--name $CONTAINER $BUILD_TAG >/dev/null
|
||||
docker network connect $WAN_NAME $CONTAINER
|
||||
|
||||
|
|
Loading…
Reference in New Issue