vnet_template: Add ipv6 for vnet0

This commit is contained in:
tschettervictor
2025-06-02 18:10:26 -06:00
committed by GitHub
parent 8903035467
commit 535d84b64d

View File

@@ -2,9 +2,14 @@ ARG EPAIR
ARG GATEWAY
ARG GATEWAY6
ARG IFCONFIG="SYNCDHCP"
ARG IFCONFIG6
SYSRC ifconfig_${EPAIR}_name=vnet0
SYSRC ifconfig_vnet0="${IFCONFIG}"
# Apply IFCONFIG6 if set
CMD if [ -n "${IFCONFIG6}" ]; then /usr/sbin/sysrc ifconfig_vnet0_ipv6="${IFCONFIG6}"; fi
# GATEWAY will be empty for a DHCP config. -- cwells
CMD if [ -n "${GATEWAY}" ]; then /usr/sbin/sysrc defaultrouter="${GATEWAY}"; fi
CMD if [ -n "${GATEWAY6}" ]; then /usr/sbin/sysrc ipv6_defaultrouter="${GATEWAY6}"; fi