From a7a44f05964ac915b9a7f349adbaabb858c5d732 Mon Sep 17 00:00:00 2001 From: Vlastimil Holer Date: Tue, 10 Jan 2017 17:21:40 +0100 Subject: [PATCH] On Debian always use IPv4 if available, disable IPv6 autoconfiguration This feature is already present in EL scripts: b513d94c96ceb0b2efd2a1655fdad4a4f343232c c2316a74debd9ef0f1633ddbf20584b8c06ad3d3 --- base_deb.one/etc/one-context.d/10-network | 5 +++-- base_rpm.one/etc/one-context.d/10-network | 1 - 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/base_deb.one/etc/one-context.d/10-network b/base_deb.one/etc/one-context.d/10-network index 6e9be3a..811847a 100755 --- a/base_deb.one/etc/one-context.d/10-network +++ b/base_deb.one/etc/one-context.d/10-network @@ -155,6 +155,8 @@ gen_iface6_conf() { iface $DEV inet6 static address $IPV6 netmask 64 + autoconf 0 + accept_ra 0 EOT if [ -n "$MTU" ]; then @@ -213,14 +215,13 @@ EOT IPV6=$(get_iface_var "IPV6") [[ -z $IPV6 ]] && IPV6=$(get_iface_var "IP6") GATEWAY6=$(get_gateway6) - CONTEXT_FORCE_IPV4=$(get_iface_var "CONTEXT_FORCE_IPV4") [ -z "${IP}${IPV6}" ] && continue [ -z "${DEV}" ] && continue echo "auto $DEV" - [[ -z $IPV6 || -n $CONTEXT_FORCE_IPV4 ]] && gen_iface_conf + [[ -n $IP ]] && gen_iface_conf [[ -n $IPV6 ]] && gen_iface6_conf done diff --git a/base_rpm.one/etc/one-context.d/10-network b/base_rpm.one/etc/one-context.d/10-network index 83572cd..251681e 100755 --- a/base_rpm.one/etc/one-context.d/10-network +++ b/base_rpm.one/etc/one-context.d/10-network @@ -169,7 +169,6 @@ gen_network_configuration() IPV6=$(get_iface_var "IPV6") [[ -z $IPV6 ]] && IPV6=$(get_iface_var "IP6") GATEWAY6=$(get_gateway6) - CONTEXT_FORCE_IPV4=$(get_iface_var "CONTEXT_FORCE_IPV4") [ -z "${IP}${IPV6}" ] && continue [ -z "${DEV}" ] && continue