|
|
9dab26 |
From aa7ae9da7e10a5bcf190f8df3072e3864b2d8fb3 Mon Sep 17 00:00:00 2001
|
|
|
222d62 |
From: Miroslav Rezanina <mrezanin@redhat.com>
|
|
|
222d62 |
Date: Thu, 31 May 2018 19:37:55 +0200
|
|
|
222d62 |
Subject: Do not write NM_CONTROLLED=no in generated interface config files
|
|
|
222d62 |
|
|
|
222d62 |
X-downstream-only: true
|
|
|
222d62 |
Signed-off-by: Ryan McCabe <rmccabe@redhat.com>
|
|
|
222d62 |
---
|
|
|
0a07cd |
cloudinit/net/sysconfig.py | 1 -
|
|
|
0a07cd |
tests/unittests/test_net.py | 30 ------------------------------
|
|
|
0a07cd |
2 files changed, 31 deletions(-)
|
|
|
222d62 |
|
|
|
222d62 |
diff --git a/cloudinit/net/sysconfig.py b/cloudinit/net/sysconfig.py
|
|
|
9dab26 |
index 310cdf0..8bd7e88 100644
|
|
|
222d62 |
--- a/cloudinit/net/sysconfig.py
|
|
|
222d62 |
+++ b/cloudinit/net/sysconfig.py
|
|
|
9dab26 |
@@ -272,7 +272,6 @@ class Renderer(renderer.Renderer):
|
|
|
222d62 |
iface_defaults = tuple([
|
|
|
222d62 |
('ONBOOT', True),
|
|
|
222d62 |
('USERCTL', False),
|
|
|
222d62 |
- ('NM_CONTROLLED', False),
|
|
|
222d62 |
('BOOTPROTO', 'none'),
|
|
|
9dab26 |
('STARTMODE', 'auto'),
|
|
|
222d62 |
])
|
|
|
222d62 |
diff --git a/tests/unittests/test_net.py b/tests/unittests/test_net.py
|
|
|
9dab26 |
index 01119e0..a931a3e 100644
|
|
|
222d62 |
--- a/tests/unittests/test_net.py
|
|
|
222d62 |
+++ b/tests/unittests/test_net.py
|
|
|
9dab26 |
@@ -530,7 +530,6 @@ GATEWAY=172.19.3.254
|
|
|
222d62 |
HWADDR=fa:16:3e:ed:9a:59
|
|
|
222d62 |
IPADDR=172.19.1.34
|
|
|
222d62 |
NETMASK=255.255.252.0
|
|
|
222d62 |
-NM_CONTROLLED=no
|
|
|
222d62 |
ONBOOT=yes
|
|
|
9dab26 |
STARTMODE=auto
|
|
|
222d62 |
TYPE=Ethernet
|
|
|
9dab26 |
@@ -636,7 +635,6 @@ IPADDR=172.19.1.34
|
|
|
222d62 |
IPADDR1=10.0.0.10
|
|
|
222d62 |
NETMASK=255.255.252.0
|
|
|
222d62 |
NETMASK1=255.255.255.0
|
|
|
222d62 |
-NM_CONTROLLED=no
|
|
|
222d62 |
ONBOOT=yes
|
|
|
9dab26 |
STARTMODE=auto
|
|
|
222d62 |
TYPE=Ethernet
|
|
|
9dab26 |
@@ -772,7 +770,6 @@ IPV6ADDR_SECONDARIES="2001:DB9::10/64 2001:DB10::10/64"
|
|
|
222d62 |
IPV6INIT=yes
|
|
|
222d62 |
IPV6_DEFAULTGW=2001:DB8::1
|
|
|
222d62 |
NETMASK=255.255.252.0
|
|
|
222d62 |
-NM_CONTROLLED=no
|
|
|
222d62 |
ONBOOT=yes
|
|
|
9dab26 |
STARTMODE=auto
|
|
|
222d62 |
TYPE=Ethernet
|
|
|
9dab26 |
@@ -889,7 +886,6 @@ NETWORK_CONFIGS = {
|
|
|
222d62 |
BOOTPROTO=none
|
|
|
222d62 |
DEVICE=eth1
|
|
|
222d62 |
HWADDR=cf:d6:af:48:e8:80
|
|
|
222d62 |
- NM_CONTROLLED=no
|
|
|
222d62 |
ONBOOT=yes
|
|
|
9dab26 |
STARTMODE=auto
|
|
|
222d62 |
TYPE=Ethernet
|
|
|
9dab26 |
@@ -907,7 +903,6 @@ NETWORK_CONFIGS = {
|
|
|
222d62 |
IPADDR=192.168.21.3
|
|
|
222d62 |
NETMASK=255.255.255.0
|
|
|
0a07cd |
METRIC=10000
|
|
|
222d62 |
- NM_CONTROLLED=no
|
|
|
222d62 |
ONBOOT=yes
|
|
|
9dab26 |
STARTMODE=auto
|
|
|
222d62 |
TYPE=Ethernet
|
|
|
9dab26 |
@@ -1022,7 +1017,6 @@ NETWORK_CONFIGS = {
|
|
|
222d62 |
IPV6ADDR=2001:1::1/64
|
|
|
222d62 |
IPV6INIT=yes
|
|
|
222d62 |
NETMASK=255.255.255.0
|
|
|
222d62 |
- NM_CONTROLLED=no
|
|
|
222d62 |
ONBOOT=yes
|
|
|
9dab26 |
STARTMODE=auto
|
|
|
222d62 |
TYPE=Ethernet
|
|
|
9dab26 |
@@ -1491,7 +1485,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
|
|
222d62 |
DHCPV6C=yes
|
|
|
222d62 |
IPV6INIT=yes
|
|
|
222d62 |
MACADDR=aa:bb:cc:dd:ee:ff
|
|
|
222d62 |
- NM_CONTROLLED=no
|
|
|
222d62 |
ONBOOT=yes
|
|
|
9dab26 |
STARTMODE=auto
|
|
|
222d62 |
TYPE=Bond
|
|
|
9dab26 |
@@ -1500,7 +1493,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
|
|
222d62 |
BOOTPROTO=dhcp
|
|
|
222d62 |
DEVICE=bond0.200
|
|
|
9dab26 |
DHCLIENT_SET_DEFAULT_ROUTE=no
|
|
|
222d62 |
- NM_CONTROLLED=no
|
|
|
222d62 |
ONBOOT=yes
|
|
|
222d62 |
PHYSDEV=bond0
|
|
|
9dab26 |
STARTMODE=auto
|
|
|
9dab26 |
@@ -1519,7 +1511,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
|
|
222d62 |
IPV6_DEFAULTGW=2001:4800:78ff:1b::1
|
|
|
0a07cd |
MACADDR=bb:bb:bb:bb:bb:aa
|
|
|
222d62 |
NETMASK=255.255.255.0
|
|
|
222d62 |
- NM_CONTROLLED=no
|
|
|
222d62 |
ONBOOT=yes
|
|
|
222d62 |
PRIO=22
|
|
|
9dab26 |
STARTMODE=auto
|
|
|
9dab26 |
@@ -1530,7 +1521,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
|
|
222d62 |
BOOTPROTO=none
|
|
|
222d62 |
DEVICE=eth0
|
|
|
222d62 |
HWADDR=c0:d6:9f:2c:e8:80
|
|
|
222d62 |
- NM_CONTROLLED=no
|
|
|
222d62 |
ONBOOT=yes
|
|
|
9dab26 |
STARTMODE=auto
|
|
|
222d62 |
TYPE=Ethernet
|
|
|
9dab26 |
@@ -1548,7 +1538,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
|
|
222d62 |
MTU=1500
|
|
|
222d62 |
NETMASK=255.255.255.0
|
|
|
222d62 |
NETMASK1=255.255.255.0
|
|
|
222d62 |
- NM_CONTROLLED=no
|
|
|
222d62 |
ONBOOT=yes
|
|
|
222d62 |
PHYSDEV=eth0
|
|
|
9dab26 |
STARTMODE=auto
|
|
|
9dab26 |
@@ -1560,7 +1549,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
|
|
222d62 |
DEVICE=eth1
|
|
|
222d62 |
HWADDR=aa:d6:9f:2c:e8:80
|
|
|
222d62 |
MASTER=bond0
|
|
|
222d62 |
- NM_CONTROLLED=no
|
|
|
222d62 |
ONBOOT=yes
|
|
|
9dab26 |
STARTMODE=auto
|
|
|
222d62 |
SLAVE=yes
|
|
|
9dab26 |
@@ -1571,7 +1559,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
|
|
222d62 |
DEVICE=eth2
|
|
|
222d62 |
HWADDR=c0:bb:9f:2c:e8:80
|
|
|
222d62 |
MASTER=bond0
|
|
|
222d62 |
- NM_CONTROLLED=no
|
|
|
222d62 |
ONBOOT=yes
|
|
|
9dab26 |
STARTMODE=auto
|
|
|
222d62 |
SLAVE=yes
|
|
|
9dab26 |
@@ -1582,7 +1569,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
|
|
222d62 |
BRIDGE=br0
|
|
|
222d62 |
DEVICE=eth3
|
|
|
222d62 |
HWADDR=66:bb:9f:2c:e8:80
|
|
|
222d62 |
- NM_CONTROLLED=no
|
|
|
222d62 |
ONBOOT=yes
|
|
|
9dab26 |
STARTMODE=auto
|
|
|
222d62 |
TYPE=Ethernet
|
|
|
9dab26 |
@@ -1592,7 +1578,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
|
|
222d62 |
BRIDGE=br0
|
|
|
222d62 |
DEVICE=eth4
|
|
|
222d62 |
HWADDR=98:bb:9f:2c:e8:80
|
|
|
222d62 |
- NM_CONTROLLED=no
|
|
|
222d62 |
ONBOOT=yes
|
|
|
9dab26 |
STARTMODE=auto
|
|
|
222d62 |
TYPE=Ethernet
|
|
|
9dab26 |
@@ -1602,7 +1587,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
|
|
222d62 |
DEVICE=eth5
|
|
|
9dab26 |
DHCLIENT_SET_DEFAULT_ROUTE=no
|
|
|
222d62 |
HWADDR=98:bb:9f:2c:e8:8a
|
|
|
222d62 |
- NM_CONTROLLED=no
|
|
|
222d62 |
ONBOOT=no
|
|
|
9dab26 |
STARTMODE=manual
|
|
|
222d62 |
TYPE=Ethernet
|
|
|
9dab26 |
@@ -2088,7 +2072,6 @@ iface bond0 inet6 static
|
|
|
0a07cd |
MTU=9000
|
|
|
222d62 |
NETMASK=255.255.255.0
|
|
|
222d62 |
NETMASK1=255.255.255.0
|
|
|
222d62 |
- NM_CONTROLLED=no
|
|
|
222d62 |
ONBOOT=yes
|
|
|
9dab26 |
STARTMODE=auto
|
|
|
222d62 |
TYPE=Bond
|
|
|
9dab26 |
@@ -2099,7 +2082,6 @@ iface bond0 inet6 static
|
|
|
222d62 |
DEVICE=bond0s0
|
|
|
222d62 |
HWADDR=aa:bb:cc:dd:e8:00
|
|
|
222d62 |
MASTER=bond0
|
|
|
222d62 |
- NM_CONTROLLED=no
|
|
|
222d62 |
ONBOOT=yes
|
|
|
222d62 |
SLAVE=yes
|
|
|
9dab26 |
STARTMODE=auto
|
|
|
9dab26 |
@@ -2122,7 +2104,6 @@ iface bond0 inet6 static
|
|
|
222d62 |
DEVICE=bond0s1
|
|
|
222d62 |
HWADDR=aa:bb:cc:dd:e8:01
|
|
|
222d62 |
MASTER=bond0
|
|
|
222d62 |
- NM_CONTROLLED=no
|
|
|
222d62 |
ONBOOT=yes
|
|
|
222d62 |
SLAVE=yes
|
|
|
9dab26 |
STARTMODE=auto
|
|
|
9dab26 |
@@ -2161,7 +2142,6 @@ iface bond0 inet6 static
|
|
|
222d62 |
BOOTPROTO=none
|
|
|
222d62 |
DEVICE=en0
|
|
|
222d62 |
HWADDR=aa:bb:cc:dd:e8:00
|
|
|
222d62 |
- NM_CONTROLLED=no
|
|
|
222d62 |
ONBOOT=yes
|
|
|
9dab26 |
STARTMODE=auto
|
|
|
222d62 |
TYPE=Ethernet
|
|
|
9dab26 |
@@ -2180,7 +2160,6 @@ iface bond0 inet6 static
|
|
|
0a07cd |
MTU=2222
|
|
|
222d62 |
NETMASK=255.255.255.0
|
|
|
222d62 |
NETMASK1=255.255.255.0
|
|
|
222d62 |
- NM_CONTROLLED=no
|
|
|
222d62 |
ONBOOT=yes
|
|
|
222d62 |
PHYSDEV=en0
|
|
|
9dab26 |
STARTMODE=auto
|
|
|
9dab26 |
@@ -2222,7 +2201,6 @@ iface bond0 inet6 static
|
|
|
222d62 |
DEVICE=br0
|
|
|
222d62 |
IPADDR=192.168.2.2
|
|
|
222d62 |
NETMASK=255.255.255.0
|
|
|
222d62 |
- NM_CONTROLLED=no
|
|
|
222d62 |
ONBOOT=yes
|
|
|
222d62 |
PRIO=22
|
|
|
9dab26 |
STARTMODE=auto
|
|
|
9dab26 |
@@ -2238,7 +2216,6 @@ iface bond0 inet6 static
|
|
|
9dab26 |
IPADDR6=2001:1::100/96
|
|
|
222d62 |
IPV6ADDR=2001:1::100/96
|
|
|
222d62 |
IPV6INIT=yes
|
|
|
222d62 |
- NM_CONTROLLED=no
|
|
|
222d62 |
ONBOOT=yes
|
|
|
9dab26 |
STARTMODE=auto
|
|
|
222d62 |
TYPE=Ethernet
|
|
|
9dab26 |
@@ -2252,7 +2229,6 @@ iface bond0 inet6 static
|
|
|
9dab26 |
IPADDR6=2001:1::101/96
|
|
|
222d62 |
IPV6ADDR=2001:1::101/96
|
|
|
222d62 |
IPV6INIT=yes
|
|
|
222d62 |
- NM_CONTROLLED=no
|
|
|
222d62 |
ONBOOT=yes
|
|
|
9dab26 |
STARTMODE=auto
|
|
|
222d62 |
TYPE=Ethernet
|
|
|
9dab26 |
@@ -2327,7 +2303,6 @@ iface bond0 inet6 static
|
|
|
222d62 |
HWADDR=52:54:00:12:34:00
|
|
|
222d62 |
IPADDR=192.168.1.2
|
|
|
222d62 |
NETMASK=255.255.255.0
|
|
|
222d62 |
- NM_CONTROLLED=no
|
|
|
222d62 |
ONBOOT=no
|
|
|
9dab26 |
STARTMODE=manual
|
|
|
222d62 |
TYPE=Ethernet
|
|
|
9dab26 |
@@ -2338,7 +2313,6 @@ iface bond0 inet6 static
|
|
|
222d62 |
DEVICE=eth1
|
|
|
222d62 |
HWADDR=52:54:00:12:34:aa
|
|
|
222d62 |
MTU=1480
|
|
|
222d62 |
- NM_CONTROLLED=no
|
|
|
222d62 |
ONBOOT=yes
|
|
|
9dab26 |
STARTMODE=auto
|
|
|
222d62 |
TYPE=Ethernet
|
|
|
9dab26 |
@@ -2348,7 +2322,6 @@ iface bond0 inet6 static
|
|
|
222d62 |
BOOTPROTO=none
|
|
|
222d62 |
DEVICE=eth2
|
|
|
222d62 |
HWADDR=52:54:00:12:34:ff
|
|
|
222d62 |
- NM_CONTROLLED=no
|
|
|
222d62 |
ONBOOT=no
|
|
|
9dab26 |
STARTMODE=manual
|
|
|
222d62 |
TYPE=Ethernet
|
|
|
9dab26 |
@@ -2766,7 +2739,6 @@ class TestRhelSysConfigRendering(CiTestCase):
|
|
|
222d62 |
BOOTPROTO=dhcp
|
|
|
222d62 |
DEVICE=eth1000
|
|
|
9dab26 |
HWADDR=07-1c-c6-75-a4-be
|
|
|
222d62 |
-NM_CONTROLLED=no
|
|
|
222d62 |
ONBOOT=yes
|
|
|
9dab26 |
STARTMODE=auto
|
|
|
222d62 |
TYPE=Ethernet
|
|
|
9dab26 |
@@ -2888,7 +2860,6 @@ GATEWAY=10.0.2.2
|
|
|
222d62 |
HWADDR=52:54:00:12:34:00
|
|
|
222d62 |
IPADDR=10.0.2.15
|
|
|
222d62 |
NETMASK=255.255.255.0
|
|
|
222d62 |
-NM_CONTROLLED=no
|
|
|
222d62 |
ONBOOT=yes
|
|
|
9dab26 |
STARTMODE=auto
|
|
|
222d62 |
TYPE=Ethernet
|
|
|
9dab26 |
@@ -2961,7 +2932,6 @@ USERCTL=no
|
|
|
222d62 |
#
|
|
|
222d62 |
BOOTPROTO=dhcp
|
|
|
222d62 |
DEVICE=eth0
|
|
|
222d62 |
-NM_CONTROLLED=no
|
|
|
222d62 |
ONBOOT=yes
|
|
|
9dab26 |
STARTMODE=auto
|
|
|
222d62 |
TYPE=Ethernet
|
|
|
222d62 |
--
|
|
|
9dab26 |
1.8.3.1
|
|
|
222d62 |
|