nixos/network-interfaces: do not try to enable or disable ipv6 in container
This commit is contained in:
parent
498c1e25fb
commit
2297f31339
|
@ -401,9 +401,11 @@ in
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
# Disable or enable IPv6.
|
# Disable or enable IPv6.
|
||||||
if [ -e /proc/sys/net/ipv6/conf/all/disable_ipv6 ]; then
|
${optionalString (!config.boot.isContainer) ''
|
||||||
echo ${if cfg.enableIPv6 then "0" else "1"} > /proc/sys/net/ipv6/conf/all/disable_ipv6
|
if [ -e /proc/sys/net/ipv6/conf/all/disable_ipv6 ]; then
|
||||||
fi
|
echo ${if cfg.enableIPv6 then "0" else "1"} > /proc/sys/net/ipv6/conf/all/disable_ipv6
|
||||||
|
fi
|
||||||
|
''}
|
||||||
|
|
||||||
# Set the default gateway.
|
# Set the default gateway.
|
||||||
${optionalString (cfg.defaultGateway != "") ''
|
${optionalString (cfg.defaultGateway != "") ''
|
||||||
|
|
Loading…
Reference in New Issue