!193 upgrade version to 23.4.1
From: @tong_1001 Reviewed-by: @gaoruoshu Signed-off-by: @gaoruoshu
This commit is contained in:
commit
bee4bcfb88
@ -16,11 +16,11 @@ Signed-off-by: Ryan McCabe <rmccabe@redhat.com>
|
||||
cloudinit/net/sysconfig.py | 1 -
|
||||
tests/unittests/cmd/devel/test_net_convert.py | 1 -
|
||||
tests/unittests/distros/test_netconfig.py | 8 ---
|
||||
tests/unittests/test_net.py | 51 -------------------
|
||||
4 files changed, 61 deletions(-)
|
||||
tests/unittests/test_net.py | 53 -------------------
|
||||
4 files changed, 63 deletions(-)
|
||||
|
||||
diff --git a/cloudinit/net/sysconfig.py b/cloudinit/net/sysconfig.py
|
||||
index 5c81748..c28f1bd 100644
|
||||
index cf55e83..030e6aa 100644
|
||||
--- a/cloudinit/net/sysconfig.py
|
||||
+++ b/cloudinit/net/sysconfig.py
|
||||
@@ -317,7 +317,6 @@ class Renderer(renderer.Renderer):
|
||||
@ -32,7 +32,7 @@ index 5c81748..c28f1bd 100644
|
||||
},
|
||||
"suse": {"BOOTPROTO": "static", "STARTMODE": "auto"},
|
||||
diff --git a/tests/unittests/cmd/devel/test_net_convert.py b/tests/unittests/cmd/devel/test_net_convert.py
|
||||
index 7165475..e0114a2 100644
|
||||
index fb72963..7b9121b 100644
|
||||
--- a/tests/unittests/cmd/devel/test_net_convert.py
|
||||
+++ b/tests/unittests/cmd/devel/test_net_convert.py
|
||||
@@ -62,7 +62,6 @@ SAMPLE_SYSCONFIG_CONTENT = """\
|
||||
@ -44,7 +44,7 @@ index 7165475..e0114a2 100644
|
||||
TYPE=Ethernet
|
||||
USERCTL=no
|
||||
diff --git a/tests/unittests/distros/test_netconfig.py b/tests/unittests/distros/test_netconfig.py
|
||||
index b1c89ce..7f9ac05 100644
|
||||
index 7ba430f..962ff7f 100644
|
||||
--- a/tests/unittests/distros/test_netconfig.py
|
||||
+++ b/tests/unittests/distros/test_netconfig.py
|
||||
@@ -723,7 +723,6 @@ class TestNetCfgDistroRedhat(TestNetCfgDistroBase):
|
||||
@ -112,7 +112,7 @@ index b1c89ce..7f9ac05 100644
|
||||
PHYSDEV=eth0
|
||||
USERCTL=no
|
||||
diff --git a/tests/unittests/test_net.py b/tests/unittests/test_net.py
|
||||
index f1e91ef..5f17163 100644
|
||||
index c550953..052b067 100644
|
||||
--- a/tests/unittests/test_net.py
|
||||
+++ b/tests/unittests/test_net.py
|
||||
@@ -585,7 +585,6 @@ GATEWAY=172.19.3.254
|
||||
@ -139,7 +139,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no
|
||||
@@ -1091,7 +1088,6 @@ NETWORK_CONFIGS = {
|
||||
@@ -1143,7 +1140,6 @@ NETWORK_CONFIGS = {
|
||||
BOOTPROTO=none
|
||||
DEVICE=eth1
|
||||
HWADDR=cf:d6:af:48:e8:80
|
||||
@ -147,7 +147,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no"""
|
||||
@@ -1110,7 +1106,6 @@ NETWORK_CONFIGS = {
|
||||
@@ -1162,7 +1158,6 @@ NETWORK_CONFIGS = {
|
||||
IPADDR=192.168.21.3
|
||||
NETMASK=255.255.255.0
|
||||
METRIC=10000
|
||||
@ -155,7 +155,23 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no"""
|
||||
@@ -1357,7 +1352,6 @@ NETWORK_CONFIGS = {
|
||||
@@ -1319,7 +1314,6 @@ NETWORK_CONFIGS = {
|
||||
BOOTPROTO=none
|
||||
DEVICE=eth1
|
||||
HWADDR=cf:d6:af:48:e8:80
|
||||
- NM_CONTROLLED=no
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no"""
|
||||
@@ -1338,7 +1332,6 @@ NETWORK_CONFIGS = {
|
||||
IPADDR=192.168.21.3
|
||||
NETMASK=255.255.255.0
|
||||
METRIC=10000
|
||||
- NM_CONTROLLED=no
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no"""
|
||||
@@ -1581,7 +1574,6 @@ NETWORK_CONFIGS = {
|
||||
IPV6_AUTOCONF=no
|
||||
IPV6_FORCE_ACCEPT_RA=no
|
||||
NETMASK=255.255.255.0
|
||||
@ -163,7 +179,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no
|
||||
@@ -1501,7 +1495,6 @@ NETWORK_CONFIGS = {
|
||||
@@ -1725,7 +1717,6 @@ NETWORK_CONFIGS = {
|
||||
DHCPV6C=yes
|
||||
IPV6INIT=yes
|
||||
DEVICE=iface0
|
||||
@ -171,7 +187,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no
|
||||
@@ -1592,7 +1585,6 @@ NETWORK_CONFIGS = {
|
||||
@@ -1816,7 +1807,6 @@ NETWORK_CONFIGS = {
|
||||
IPV6INIT=yes
|
||||
IPV6_FORCE_ACCEPT_RA=yes
|
||||
DEVICE=iface0
|
||||
@ -179,7 +195,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no
|
||||
@@ -1668,7 +1660,6 @@ NETWORK_CONFIGS = {
|
||||
@@ -1892,7 +1882,6 @@ NETWORK_CONFIGS = {
|
||||
IPV6INIT=yes
|
||||
IPV6_FORCE_ACCEPT_RA=no
|
||||
DEVICE=iface0
|
||||
@ -187,7 +203,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no
|
||||
@@ -1732,7 +1723,6 @@ NETWORK_CONFIGS = {
|
||||
@@ -1956,7 +1945,6 @@ NETWORK_CONFIGS = {
|
||||
IPV6_AUTOCONF=yes
|
||||
IPV6INIT=yes
|
||||
DEVICE=iface0
|
||||
@ -195,7 +211,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no
|
||||
@@ -1787,7 +1777,6 @@ NETWORK_CONFIGS = {
|
||||
@@ -2014,7 +2002,6 @@ NETWORK_CONFIGS = {
|
||||
IPV6_AUTOCONF=no
|
||||
IPV6_FORCE_ACCEPT_RA=no
|
||||
DEVICE=iface0
|
||||
@ -203,7 +219,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no
|
||||
@@ -1844,7 +1833,6 @@ NETWORK_CONFIGS = {
|
||||
@@ -2071,7 +2058,6 @@ NETWORK_CONFIGS = {
|
||||
IPV6_AUTOCONF=yes
|
||||
IPV6INIT=yes
|
||||
DEVICE=iface0
|
||||
@ -211,15 +227,15 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no
|
||||
@@ -1926,7 +1914,6 @@ NETWORK_CONFIGS = {
|
||||
IPV6_AUTOCONF=no
|
||||
@@ -2157,7 +2143,6 @@ NETWORK_CONFIGS = {
|
||||
IPV6_FAILURE_FATAL=yes
|
||||
IPV6_FORCE_ACCEPT_RA=yes
|
||||
DEVICE=iface0
|
||||
- NM_CONTROLLED=no
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no
|
||||
@@ -1967,7 +1954,6 @@ NETWORK_CONFIGS = {
|
||||
@@ -2198,7 +2183,6 @@ NETWORK_CONFIGS = {
|
||||
"""\
|
||||
BOOTPROTO=dhcp
|
||||
DEVICE=iface0
|
||||
@ -227,7 +243,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no
|
||||
@@ -2044,7 +2030,6 @@ NETWORK_CONFIGS = {
|
||||
@@ -2275,7 +2259,6 @@ NETWORK_CONFIGS = {
|
||||
BOOTPROTO=dhcp
|
||||
DEVICE=iface0
|
||||
ETHTOOL_OPTS="wol g"
|
||||
@ -235,7 +251,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no
|
||||
@@ -2388,7 +2373,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
||||
@@ -2619,7 +2602,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
||||
DHCPV6C=yes
|
||||
IPV6INIT=yes
|
||||
MACADDR=aa:bb:cc:dd:ee:ff
|
||||
@ -243,7 +259,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Bond
|
||||
USERCTL=no"""
|
||||
@@ -2398,7 +2382,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
||||
@@ -2629,7 +2611,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
||||
BOOTPROTO=dhcp
|
||||
DEVICE=bond0.200
|
||||
DHCLIENT_SET_DEFAULT_ROUTE=no
|
||||
@ -251,7 +267,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
PHYSDEV=bond0
|
||||
USERCTL=no
|
||||
@@ -2418,7 +2401,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
||||
@@ -2649,7 +2630,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
||||
IPV6_DEFAULTGW=2001:4800:78ff:1b::1
|
||||
MACADDR=bb:bb:bb:bb:bb:aa
|
||||
NETMASK=255.255.255.0
|
||||
@ -259,7 +275,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
PRIO=22
|
||||
STP=no
|
||||
@@ -2430,7 +2412,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
||||
@@ -2661,7 +2641,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
||||
BOOTPROTO=none
|
||||
DEVICE=eth0
|
||||
HWADDR=c0:d6:9f:2c:e8:80
|
||||
@ -267,7 +283,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no"""
|
||||
@@ -2449,7 +2430,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
||||
@@ -2680,7 +2659,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
||||
MTU=1500
|
||||
NETMASK=255.255.255.0
|
||||
NETMASK1=255.255.255.0
|
||||
@ -275,7 +291,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
PHYSDEV=eth0
|
||||
USERCTL=no
|
||||
@@ -2461,7 +2441,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
||||
@@ -2692,7 +2670,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
||||
DEVICE=eth1
|
||||
HWADDR=aa:d6:9f:2c:e8:80
|
||||
MASTER=bond0
|
||||
@ -283,7 +299,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
SLAVE=yes
|
||||
TYPE=Ethernet
|
||||
@@ -2473,7 +2452,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
||||
@@ -2704,7 +2681,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
||||
DEVICE=eth2
|
||||
HWADDR=c0:bb:9f:2c:e8:80
|
||||
MASTER=bond0
|
||||
@ -291,7 +307,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
SLAVE=yes
|
||||
TYPE=Ethernet
|
||||
@@ -2485,7 +2463,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
||||
@@ -2716,7 +2692,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
||||
BRIDGE=br0
|
||||
DEVICE=eth3
|
||||
HWADDR=66:bb:9f:2c:e8:80
|
||||
@ -299,7 +315,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no"""
|
||||
@@ -2496,7 +2473,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
||||
@@ -2727,7 +2702,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
||||
BRIDGE=br0
|
||||
DEVICE=eth4
|
||||
HWADDR=98:bb:9f:2c:e8:80
|
||||
@ -307,7 +323,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no"""
|
||||
@@ -2507,7 +2483,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
||||
@@ -2738,7 +2712,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
||||
DEVICE=eth5
|
||||
DHCLIENT_SET_DEFAULT_ROUTE=no
|
||||
HWADDR=98:bb:9f:2c:e8:8a
|
||||
@ -315,7 +331,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=no
|
||||
TYPE=Ethernet
|
||||
USERCTL=no"""
|
||||
@@ -2520,7 +2495,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
||||
@@ -2751,7 +2724,6 @@ pre-down route del -net 10.0.0.0/8 gw 11.0.0.1 metric 3 || true
|
||||
IPADDR=192.168.200.7
|
||||
MTU=9000
|
||||
NETMASK=255.255.255.0
|
||||
@ -323,7 +339,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=InfiniBand
|
||||
USERCTL=no"""
|
||||
@@ -3242,7 +3216,6 @@ iface bond0 inet6 static
|
||||
@@ -3473,7 +3445,6 @@ iface bond0 inet6 static
|
||||
MTU=9000
|
||||
NETMASK=255.255.255.0
|
||||
NETMASK1=255.255.255.0
|
||||
@ -331,7 +347,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Bond
|
||||
USERCTL=no
|
||||
@@ -3254,7 +3227,6 @@ iface bond0 inet6 static
|
||||
@@ -3485,7 +3456,6 @@ iface bond0 inet6 static
|
||||
DEVICE=bond0s0
|
||||
HWADDR=aa:bb:cc:dd:e8:00
|
||||
MASTER=bond0
|
||||
@ -339,7 +355,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
SLAVE=yes
|
||||
TYPE=Ethernet
|
||||
@@ -3282,7 +3254,6 @@ iface bond0 inet6 static
|
||||
@@ -3513,7 +3483,6 @@ iface bond0 inet6 static
|
||||
DEVICE=bond0s1
|
||||
HWADDR=aa:bb:cc:dd:e8:01
|
||||
MASTER=bond0
|
||||
@ -347,7 +363,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
SLAVE=yes
|
||||
TYPE=Ethernet
|
||||
@@ -3431,7 +3402,6 @@ iface bond0 inet6 static
|
||||
@@ -3662,7 +3631,6 @@ iface bond0 inet6 static
|
||||
BOOTPROTO=none
|
||||
DEVICE=en0
|
||||
HWADDR=aa:bb:cc:dd:e8:00
|
||||
@ -355,7 +371,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no"""
|
||||
@@ -3452,7 +3422,6 @@ iface bond0 inet6 static
|
||||
@@ -3683,7 +3651,6 @@ iface bond0 inet6 static
|
||||
MTU=2222
|
||||
NETMASK=255.255.255.0
|
||||
NETMASK1=255.255.255.0
|
||||
@ -363,7 +379,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
PHYSDEV=en0
|
||||
USERCTL=no
|
||||
@@ -3580,7 +3549,6 @@ iface bond0 inet6 static
|
||||
@@ -3811,7 +3778,6 @@ iface bond0 inet6 static
|
||||
DEVICE=br0
|
||||
IPADDR=192.168.2.2
|
||||
NETMASK=255.255.255.0
|
||||
@ -371,7 +387,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
PRIO=22
|
||||
STP=no
|
||||
@@ -3598,7 +3566,6 @@ iface bond0 inet6 static
|
||||
@@ -3829,7 +3795,6 @@ iface bond0 inet6 static
|
||||
IPV6INIT=yes
|
||||
IPV6_AUTOCONF=no
|
||||
IPV6_FORCE_ACCEPT_RA=no
|
||||
@ -379,7 +395,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no
|
||||
@@ -3614,7 +3581,6 @@ iface bond0 inet6 static
|
||||
@@ -3845,7 +3810,6 @@ iface bond0 inet6 static
|
||||
IPV6INIT=yes
|
||||
IPV6_AUTOCONF=no
|
||||
IPV6_FORCE_ACCEPT_RA=no
|
||||
@ -387,7 +403,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no
|
||||
@@ -3799,7 +3765,6 @@ iface bond0 inet6 static
|
||||
@@ -4030,7 +3994,6 @@ iface bond0 inet6 static
|
||||
HWADDR=52:54:00:12:34:00
|
||||
IPADDR=192.168.1.2
|
||||
NETMASK=255.255.255.0
|
||||
@ -395,7 +411,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=no
|
||||
TYPE=Ethernet
|
||||
USERCTL=no
|
||||
@@ -3811,7 +3776,6 @@ iface bond0 inet6 static
|
||||
@@ -4042,7 +4005,6 @@ iface bond0 inet6 static
|
||||
DEVICE=eth1
|
||||
HWADDR=52:54:00:12:34:aa
|
||||
MTU=1480
|
||||
@ -403,7 +419,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no
|
||||
@@ -3822,7 +3786,6 @@ iface bond0 inet6 static
|
||||
@@ -4053,7 +4015,6 @@ iface bond0 inet6 static
|
||||
BOOTPROTO=none
|
||||
DEVICE=eth2
|
||||
HWADDR=52:54:00:12:34:ff
|
||||
@ -411,7 +427,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=no
|
||||
TYPE=Ethernet
|
||||
USERCTL=no
|
||||
@@ -3907,7 +3870,6 @@ iface bond0 inet6 static
|
||||
@@ -4138,7 +4099,6 @@ iface bond0 inet6 static
|
||||
BOOTPROTO=none
|
||||
DEVICE=eth0
|
||||
HWADDR=cf:d6:af:48:e8:80
|
||||
@ -419,7 +435,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no"""
|
||||
@@ -4499,7 +4461,6 @@ class TestRhelSysConfigRendering(CiTestCase):
|
||||
@@ -4736,7 +4696,6 @@ class TestRhelSysConfigRendering(CiTestCase):
|
||||
BOOTPROTO=dhcp
|
||||
DEVICE=eth1000
|
||||
HWADDR=07-1c-c6-75-a4-be
|
||||
@ -427,7 +443,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no
|
||||
@@ -4711,7 +4672,6 @@ GATEWAY=10.0.2.2
|
||||
@@ -4948,7 +4907,6 @@ GATEWAY=10.0.2.2
|
||||
HWADDR=52:54:00:12:34:00
|
||||
IPADDR=10.0.2.15
|
||||
NETMASK=255.255.255.0
|
||||
@ -435,7 +451,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no
|
||||
@@ -4742,7 +4702,6 @@ HWADDR=fa:16:3e:25:b4:59
|
||||
@@ -4979,7 +4937,6 @@ HWADDR=fa:16:3e:25:b4:59
|
||||
IPADDR=51.68.89.122
|
||||
MTU=1500
|
||||
NETMASK=255.255.240.0
|
||||
@ -443,7 +459,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no
|
||||
@@ -4756,7 +4715,6 @@ DEVICE=eth1
|
||||
@@ -4993,7 +4950,6 @@ DEVICE=eth1
|
||||
DHCLIENT_SET_DEFAULT_ROUTE=no
|
||||
HWADDR=fa:16:3e:b1:ca:29
|
||||
MTU=9000
|
||||
@ -451,7 +467,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no
|
||||
@@ -4781,7 +4739,6 @@ USERCTL=no
|
||||
@@ -5018,7 +4974,6 @@ USERCTL=no
|
||||
#
|
||||
BOOTPROTO=dhcp
|
||||
DEVICE=eth0
|
||||
@ -459,7 +475,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no
|
||||
@@ -5008,7 +4965,6 @@ USERCTL=no
|
||||
@@ -5251,7 +5206,6 @@ USERCTL=no
|
||||
IPV6_FORCE_ACCEPT_RA=no
|
||||
IPV6_DEFAULTGW=2001:db8::1
|
||||
NETMASK=255.255.255.0
|
||||
@ -467,7 +483,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no
|
||||
@@ -5040,7 +4996,6 @@ USERCTL=no
|
||||
@@ -5283,7 +5237,6 @@ USERCTL=no
|
||||
"""\
|
||||
BOOTPROTO=none
|
||||
DEVICE=eno1
|
||||
@ -475,7 +491,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no
|
||||
@@ -5053,7 +5008,6 @@ USERCTL=no
|
||||
@@ -5296,7 +5249,6 @@ USERCTL=no
|
||||
IPADDR=192.6.1.9
|
||||
MTU=1495
|
||||
NETMASK=255.255.255.0
|
||||
@ -483,7 +499,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
PHYSDEV=eno1
|
||||
USERCTL=no
|
||||
@@ -5089,7 +5043,6 @@ USERCTL=no
|
||||
@@ -5332,7 +5284,6 @@ USERCTL=no
|
||||
IPADDR=10.101.8.65
|
||||
MTU=1334
|
||||
NETMASK=255.255.255.192
|
||||
@ -491,7 +507,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Bond
|
||||
USERCTL=no
|
||||
@@ -5101,7 +5054,6 @@ USERCTL=no
|
||||
@@ -5344,7 +5295,6 @@ USERCTL=no
|
||||
BOOTPROTO=none
|
||||
DEVICE=enp0s0
|
||||
MASTER=bond0
|
||||
@ -499,7 +515,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
SLAVE=yes
|
||||
TYPE=Bond
|
||||
@@ -5114,7 +5066,6 @@ USERCTL=no
|
||||
@@ -5357,7 +5307,6 @@ USERCTL=no
|
||||
BOOTPROTO=none
|
||||
DEVICE=enp0s1
|
||||
MASTER=bond0
|
||||
@ -507,7 +523,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
SLAVE=yes
|
||||
TYPE=Bond
|
||||
@@ -5145,7 +5096,6 @@ USERCTL=no
|
||||
@@ -5388,7 +5337,6 @@ USERCTL=no
|
||||
DEVICE=eno1
|
||||
HWADDR=07-1c-c6-75-a4-be
|
||||
METRIC=100
|
||||
@ -515,7 +531,7 @@ index f1e91ef..5f17163 100644
|
||||
ONBOOT=yes
|
||||
TYPE=Ethernet
|
||||
USERCTL=no
|
||||
@@ -5236,7 +5186,6 @@ USERCTL=no
|
||||
@@ -5479,7 +5427,6 @@ USERCTL=no
|
||||
IPV6_FORCE_ACCEPT_RA=no
|
||||
MTU=1400
|
||||
NETMASK=255.255.248.0
|
||||
@ -524,5 +540,5 @@ index f1e91ef..5f17163 100644
|
||||
TYPE=Ethernet
|
||||
USERCTL=no
|
||||
--
|
||||
2.33.0
|
||||
2.27.0
|
||||
|
||||
@ -1,30 +0,0 @@
|
||||
From 2009784e662c03d8d223161c003959511be31518 Mon Sep 17 00:00:00 2001
|
||||
From: yang_zhuang_zhuang <yangzhuangzhuang1@huawei.com>
|
||||
Date: Thu, 18 Mar 2021 15:16:35 +0800
|
||||
Subject: [PATCH] Fix the error-level logs displayed for the cloud-init-local service
|
||||
|
||||
After cloud-init is installed,restart the host and check the status of the cloud-init-local service.The following error log is displayed:stages.py[ERROR]:Unable to render networking.
|
||||
The value returned by return (util.system_info() ['variant'] in KNOWN_DISTROS) in the sysconfig.py file is not in the given list of KNOWN_DISTROS.
|
||||
The actual return value is linux.
|
||||
|
||||
Reference:https://bugs.almalinux.org/view.php?id=32&nbn=1
|
||||
---
|
||||
cloudinit/net/sysconfig.py | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/cloudinit/net/sysconfig.py b/cloudinit/net/sysconfig.py
|
||||
index 8a60c95..5c81748 100644
|
||||
--- a/cloudinit/net/sysconfig.py
|
||||
+++ b/cloudinit/net/sysconfig.py
|
||||
@@ -27,7 +27,7 @@ KNOWN_DISTROS = [
|
||||
"eurolinux",
|
||||
"fedora",
|
||||
"miraclelinux",
|
||||
- "openEuler",
|
||||
+ "openeuler",
|
||||
"OpenCloudOS",
|
||||
"openmandriva",
|
||||
"rhel",
|
||||
--
|
||||
2.27.0
|
||||
|
||||
@ -7,23 +7,23 @@ reason: add variable to forbid temporary directory
|
||||
|
||||
Signed-off-by: chengquan <chengquan3@huawei.com>
|
||||
---
|
||||
setup.py | 14 +++++++++++---
|
||||
1 file changed, 11 insertions(+), 3 deletions(-)
|
||||
setup.py | 15 ++++++++++++---
|
||||
1 file changed, 12 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/setup.py b/setup.py
|
||||
index 55b929a..34fb29b 100644
|
||||
index c3659cc..b4847ac 100644
|
||||
--- a/setup.py
|
||||
+++ b/setup.py
|
||||
@@ -90,6 +90,8 @@ def read_requires():
|
||||
deps = subprocess.check_output(cmd)
|
||||
return deps.decode("utf-8").splitlines()
|
||||
@@ -49,6 +49,8 @@ RENDERED_TMPD_PREFIX = "RENDERED_TEMPD"
|
||||
VARIANT = None
|
||||
PREFIX = None
|
||||
|
||||
+# add variable to forbid tmp dir
|
||||
+num = 0
|
||||
|
||||
def render_tmpl(template, mode=None):
|
||||
def render_tmpl(template, mode=None, is_yaml=False):
|
||||
"""render template into a tmpdir under same dir as setup.py
|
||||
@@ -110,7 +112,10 @@ def render_tmpl(template, mode=None):
|
||||
@@ -69,7 +71,10 @@ def render_tmpl(template, mode=None, is_yaml=False):
|
||||
return template
|
||||
|
||||
topdir = os.path.dirname(sys.argv[0])
|
||||
@ -33,20 +33,21 @@ index 55b929a..34fb29b 100644
|
||||
+ tmpd = os.path.abspath(topdir + str(num))
|
||||
+ num = num + 1
|
||||
atexit.register(shutil.rmtree, tmpd)
|
||||
bname = os.path.basename(template).rstrip(tmpl_ext)
|
||||
fpath = os.path.join(tmpd, bname)
|
||||
@@ -136,6 +141,9 @@ def render_tmpl(template, mode=None):
|
||||
# return path relative to setup.py
|
||||
bname = os.path.basename(template)
|
||||
ename, ext = os.path.splitext(bname)
|
||||
@@ -99,6 +104,10 @@ def render_tmpl(template, mode=None, is_yaml=False):
|
||||
return os.path.join(os.path.basename(tmpd), bname)
|
||||
|
||||
|
||||
+def sort_files(file_list):
|
||||
+ file_list.sort()
|
||||
+ return file_list
|
||||
|
||||
+
|
||||
# User can set the variant for template rendering
|
||||
if "--distro" in sys.argv:
|
||||
@@ -153,11 +161,11 @@ INITSYS_FILES = {
|
||||
"systemd": [
|
||||
for a in sys.argv:
|
||||
if a.startswith("--distro"):
|
||||
@@ -139,11 +148,11 @@ INITSYS_FILES = {
|
||||
"systemd": lambda: [
|
||||
render_tmpl(f)
|
||||
for f in (
|
||||
- glob("systemd/*.tmpl")
|
||||
@ -58,7 +59,7 @@ index 55b929a..34fb29b 100644
|
||||
+ )))
|
||||
if (is_f(f) and not is_generator(f))
|
||||
],
|
||||
"systemd.generators": [
|
||||
"systemd.generators": lambda: [
|
||||
--
|
||||
2.27.0
|
||||
|
||||
|
||||
@ -1,116 +0,0 @@
|
||||
From 2fb656fd991d788ed54e098815d93458e46f069e Mon Sep 17 00:00:00 2001
|
||||
From: Brett Holman <brett.holman@canonical.com>
|
||||
Date: Fri, 24 Nov 2023 15:54:09 +0000
|
||||
Subject: [PATCH] fix: Don't loosen the permissions of the log file (#4628)
|
||||
|
||||
Previous implementations loosened permissions in non-default scenarios.
|
||||
|
||||
Fixes GH-4243
|
||||
---
|
||||
cloudinit/stages.py | 15 +++++++++++-
|
||||
tests/unittests/test_stages.py | 45 +++++++++++++++++++++++++---------
|
||||
2 files changed, 47 insertions(+), 13 deletions(-)
|
||||
|
||||
diff --git a/cloudinit/stages.py b/cloudinit/stages.py
|
||||
index 509d8f7..79072e7 100644
|
||||
--- a/cloudinit/stages.py
|
||||
+++ b/cloudinit/stages.py
|
||||
@@ -8,6 +8,7 @@ import copy
|
||||
import os
|
||||
import sys
|
||||
from collections import namedtuple
|
||||
+from contextlib import suppress
|
||||
from typing import Dict, Iterable, List, Optional, Set
|
||||
|
||||
from cloudinit import cloud, distros, handlers, helpers, importer
|
||||
@@ -199,13 +200,25 @@ class Init:
|
||||
def initialize(self):
|
||||
self._initialize_filesystem()
|
||||
|
||||
+ @staticmethod
|
||||
+ def _get_strictest_mode(mode_1: int, mode_2: int) -> int:
|
||||
+ return mode_1 & mode_2
|
||||
+
|
||||
def _initialize_filesystem(self):
|
||||
+ mode = 0o640
|
||||
+
|
||||
util.ensure_dirs(self._initial_subdirs())
|
||||
log_file = util.get_cfg_option_str(self.cfg, "def_log_file")
|
||||
if log_file:
|
||||
# At this point the log file should have already been created
|
||||
# in the setupLogging function of log.py
|
||||
- util.ensure_file(log_file, mode=0o640, preserve_mode=False)
|
||||
+ with suppress(OSError):
|
||||
+ mode = self._get_strictest_mode(
|
||||
+ 0o640, util.get_permissions(log_file)
|
||||
+ )
|
||||
+
|
||||
+ # set file mode to the strictest of 0o640 and the current mode
|
||||
+ util.ensure_file(log_file, mode, preserve_mode=False)
|
||||
perms = self.cfg.get("syslog_fix_perms")
|
||||
if not perms:
|
||||
perms = {}
|
||||
diff --git a/tests/unittests/test_stages.py b/tests/unittests/test_stages.py
|
||||
index a61f9df..2f62eb7 100644
|
||||
--- a/tests/unittests/test_stages.py
|
||||
+++ b/tests/unittests/test_stages.py
|
||||
@@ -606,23 +606,44 @@ class TestInit_InitializeFilesystem:
|
||||
# Assert we create it 0o640 by default if it doesn't already exist
|
||||
assert 0o640 == stat.S_IMODE(log_file.stat().mode)
|
||||
|
||||
- def test_existing_file_permissions(self, init, tmpdir):
|
||||
+ @pytest.mark.parametrize(
|
||||
+ "input, expected",
|
||||
+ [
|
||||
+ (0o777, 0o640),
|
||||
+ (0o640, 0o640),
|
||||
+ (0o606, 0o600),
|
||||
+ (0o501, 0o400),
|
||||
+ ],
|
||||
+ )
|
||||
+ def test_existing_file_permissions(self, init, tmpdir, input, expected):
|
||||
"""Test file permissions are set as expected.
|
||||
|
||||
- CIS Hardening requires 640 permissions. These permissions are
|
||||
- currently hardcoded on every boot, but if there's ever a reason
|
||||
- to change this, we need to then ensure that they
|
||||
- are *not* set every boot.
|
||||
+ CIS Hardening requires file mode 0o640 or stricter. Set the
|
||||
+ permissions to the subset of 0o640 and the current
|
||||
+ mode.
|
||||
|
||||
See https://bugs.launchpad.net/cloud-init/+bug/1900837.
|
||||
"""
|
||||
log_file = tmpdir.join("cloud-init.log")
|
||||
log_file.ensure()
|
||||
- # Use a mode that will never be made the default so this test will
|
||||
- # always be valid
|
||||
- log_file.chmod(0o606)
|
||||
+ log_file.chmod(input)
|
||||
init._cfg = {"def_log_file": str(log_file)}
|
||||
-
|
||||
- init._initialize_filesystem()
|
||||
-
|
||||
- assert 0o640 == stat.S_IMODE(log_file.stat().mode)
|
||||
+ with mock.patch.object(stages.util, "ensure_file") as ensure:
|
||||
+ init._initialize_filesystem()
|
||||
+ assert expected == ensure.call_args[0][1]
|
||||
+
|
||||
+
|
||||
+@pytest.mark.parametrize(
|
||||
+ "mode_1, mode_2, expected",
|
||||
+ [
|
||||
+ (0o777, 0o640, 0o640),
|
||||
+ (0o640, 0o777, 0o640),
|
||||
+ (0o640, 0o541, 0o440),
|
||||
+ (0o111, 0o050, 0o010),
|
||||
+ (0o631, 0o640, 0o600),
|
||||
+ (0o661, 0o640, 0o640),
|
||||
+ (0o453, 0o611, 0o411),
|
||||
+ ],
|
||||
+)
|
||||
+def test_strictest_permissions(mode_1, mode_2, expected):
|
||||
+ assert expected == stages.Init._get_strictest_mode(mode_1, mode_2)
|
||||
--
|
||||
2.27.0
|
||||
|
||||
@ -1,214 +0,0 @@
|
||||
From 098429a75ea00df1d8a5670e45df6babfc37f327 Mon Sep 17 00:00:00 2001
|
||||
From: chengquan <chengquan3@huawei.com>
|
||||
Date: Thu, 8 Aug 2019 16:11:58 +0800
|
||||
Subject: [PATCH] cloud-init: cloud-init add oe os
|
||||
|
||||
reason: add oe into distros
|
||||
|
||||
Signed-off-by: chengquan <chengquan3@huawei.com>
|
||||
---
|
||||
cloudinit/config/cc_ntp.py | 2 +-
|
||||
cloudinit/config/cc_resolv_conf.py | 1 +
|
||||
cloudinit/config/cc_rh_subscription.py | 2 +-
|
||||
cloudinit/config/cc_spacewalk.py | 2 +-
|
||||
cloudinit/config/cc_yum_add_repo.py | 2 +-
|
||||
cloudinit/distros/__init__.py | 2 +-
|
||||
cloudinit/distros/openeuler.py | 12 ++++++++++++
|
||||
config/cloud.cfg.tmpl | 8 ++++----
|
||||
systemd/cloud-init-generator.tmpl | 2 +-
|
||||
systemd/cloud-init.service.tmpl | 2 +-
|
||||
tests/unittests/test_cli.py | 2 +-
|
||||
tools/render-cloudcfg | 2 +-
|
||||
12 files changed, 26 insertions(+), 13 deletions(-)
|
||||
create mode 100644 cloudinit/distros/openeuler.py
|
||||
|
||||
diff --git a/cloudinit/config/cc_ntp.py b/cloudinit/config/cc_ntp.py
|
||||
index 8d83433..508f1ed 100644
|
||||
--- a/cloudinit/config/cc_ntp.py
|
||||
+++ b/cloudinit/config/cc_ntp.py
|
||||
@@ -35,7 +35,7 @@ distros = [
|
||||
"mariner",
|
||||
"miraclelinux",
|
||||
"openbsd",
|
||||
- "openEuler",
|
||||
+ "openeuler",
|
||||
"OpenCloudOS",
|
||||
"openmandriva",
|
||||
"opensuse",
|
||||
diff --git a/cloudinit/config/cc_resolv_conf.py b/cloudinit/config/cc_resolv_conf.py
|
||||
index d8a7bfa..b642640 100644
|
||||
--- a/cloudinit/config/cc_resolv_conf.py
|
||||
+++ b/cloudinit/config/cc_resolv_conf.py
|
||||
@@ -69,6 +69,7 @@ meta: MetaSchema = {
|
||||
"sle_hpc",
|
||||
"sle-micro",
|
||||
"sles",
|
||||
+ "openeuler",
|
||||
],
|
||||
"frequency": PER_INSTANCE,
|
||||
"examples": [
|
||||
diff --git a/cloudinit/config/cc_rh_subscription.py b/cloudinit/config/cc_rh_subscription.py
|
||||
index 533862a..d92f760 100644
|
||||
--- a/cloudinit/config/cc_rh_subscription.py
|
||||
+++ b/cloudinit/config/cc_rh_subscription.py
|
||||
@@ -32,7 +32,7 @@ meta: MetaSchema = {
|
||||
"name": "Red Hat Subscription",
|
||||
"title": "Register Red Hat Enterprise Linux based system",
|
||||
"description": MODULE_DESCRIPTION,
|
||||
- "distros": ["fedora", "rhel"],
|
||||
+ "distros": ["fedora", "rhel", "openeuler"],
|
||||
"frequency": PER_INSTANCE,
|
||||
"examples": [
|
||||
dedent(
|
||||
diff --git a/cloudinit/config/cc_spacewalk.py b/cloudinit/config/cc_spacewalk.py
|
||||
index c8249e6..bd7a972 100644
|
||||
--- a/cloudinit/config/cc_spacewalk.py
|
||||
+++ b/cloudinit/config/cc_spacewalk.py
|
||||
@@ -25,7 +25,7 @@ meta: MetaSchema = {
|
||||
"name": "Spacewalk",
|
||||
"title": "Install and configure spacewalk",
|
||||
"description": MODULE_DESCRIPTION,
|
||||
- "distros": ["rhel", "fedora"],
|
||||
+ "distros": ["rhel", "fedora", "openeuler"],
|
||||
"frequency": PER_INSTANCE,
|
||||
"examples": [
|
||||
dedent(
|
||||
diff --git a/cloudinit/config/cc_yum_add_repo.py b/cloudinit/config/cc_yum_add_repo.py
|
||||
index 097493b..e565a1d 100644
|
||||
--- a/cloudinit/config/cc_yum_add_repo.py
|
||||
+++ b/cloudinit/config/cc_yum_add_repo.py
|
||||
@@ -32,7 +32,7 @@ distros = [
|
||||
"eurolinux",
|
||||
"fedora",
|
||||
"mariner",
|
||||
- "openEuler",
|
||||
+ "openeuler",
|
||||
"OpenCloudOS",
|
||||
"openmandriva",
|
||||
"photon",
|
||||
diff --git a/cloudinit/distros/__init__.py b/cloudinit/distros/__init__.py
|
||||
index ec14893..59bafe0 100644
|
||||
--- a/cloudinit/distros/__init__.py
|
||||
+++ b/cloudinit/distros/__init__.py
|
||||
@@ -72,7 +72,7 @@ OSFAMILIES = {
|
||||
"sle-micro",
|
||||
"sles",
|
||||
],
|
||||
- "openEuler": ["openEuler"],
|
||||
+ "openeuler": ["openeuler"],
|
||||
"OpenCloudOS": ["OpenCloudOS", "TencentOS"],
|
||||
}
|
||||
|
||||
diff --git a/cloudinit/distros/openeuler.py b/cloudinit/distros/openeuler.py
|
||||
new file mode 100644
|
||||
index 0000000..7505ca4
|
||||
--- /dev/null
|
||||
+++ b/cloudinit/distros/openeuler.py
|
||||
@@ -0,0 +1,12 @@
|
||||
+# Copyright (c) Huawei Technologies Co., Ltd. 2019-2019. All rights reserved.
|
||||
+# This file is part of cloud-init. See LICENSE file for license information.
|
||||
+
|
||||
+from cloudinit.distros import rhel
|
||||
+from cloudinit import log as logging
|
||||
+
|
||||
+LOG = logging.getLogger(__name__)
|
||||
+
|
||||
+class Distro(rhel.Distro):
|
||||
+ pass
|
||||
+
|
||||
+# vi: ts=4 expandtab
|
||||
diff --git a/config/cloud.cfg.tmpl b/config/cloud.cfg.tmpl
|
||||
index 4c05f63..e686770 100644
|
||||
--- a/config/cloud.cfg.tmpl
|
||||
+++ b/config/cloud.cfg.tmpl
|
||||
@@ -35,7 +35,7 @@ disable_root: false
|
||||
disable_root: true
|
||||
{% endif %}
|
||||
|
||||
-{% if variant in ["alpine", "amazon", "fedora", "openEuler", "OpenCloudOS", "openmandriva", "photon", "TencentOS"] or is_rhel %}
|
||||
+{% if variant in ["alpine", "amazon", "fedora", "openeuler", "OpenCloudOS", "openmandriva", "photon", "TencentOS"] or is_rhel %}
|
||||
{% if is_rhel %}
|
||||
mount_default_fields: [~, ~, 'auto', 'defaults,nofail,x-systemd.requires=cloud-init.service,_netdev', '0', '2']
|
||||
{% else %}
|
||||
@@ -135,7 +135,7 @@ cloud_config_modules:
|
||||
{% if is_rhel %}
|
||||
- rh_subscription
|
||||
{% endif %}
|
||||
-{% if variant in ["fedora", "mariner", "openmandriva", "photon"] or is_rhel %}
|
||||
+{% if variant in ["fedora", "mariner", "openmandriva", "photon", "openeuler"] or is_rhel %}
|
||||
{% if variant not in ["mariner", "photon"] %}
|
||||
- spacewalk
|
||||
{% endif %}
|
||||
@@ -199,7 +199,7 @@ cloud_final_modules:
|
||||
system_info:
|
||||
# This will affect which distro class gets used
|
||||
{% if variant in ["alpine", "amazon", "arch", "debian", "fedora", "freebsd",
|
||||
- "gentoo", "netbsd", "mariner", "openbsd", "openEuler", "OpenCloudOS",
|
||||
+ "gentoo", "netbsd", "mariner", "openbsd", "openeuler", "OpenCloudOS",
|
||||
"openmandriva", "photon", "suse", "TencentOS", "ubuntu"] or is_rhel %}
|
||||
distro: {{ variant }}
|
||||
{% elif variant in ["dragonfly"] %}
|
||||
@@ -254,7 +254,7 @@ system_info:
|
||||
security: http://ports.ubuntu.com/ubuntu-ports
|
||||
ssh_svcname: ssh
|
||||
{% elif variant in ["alpine", "amazon", "arch", "fedora",
|
||||
- "gentoo", "openEuler", "OpenCloudOS", "openmandriva", "suse", "TencentOS"] or is_rhel %}
|
||||
+ "gentoo", "openeuler", "OpenCloudOS", "openmandriva", "suse", "TencentOS"] or is_rhel %}
|
||||
# Default user name + that default users groups (if added/used)
|
||||
default_user:
|
||||
{% if variant == "amazon" %}
|
||||
diff --git a/systemd/cloud-init-generator.tmpl b/systemd/cloud-init-generator.tmpl
|
||||
index d71e3b8..783ae76 100644
|
||||
--- a/systemd/cloud-init-generator.tmpl
|
||||
+++ b/systemd/cloud-init-generator.tmpl
|
||||
@@ -21,7 +21,7 @@ CLOUD_SYSTEM_TARGET="/usr/lib/systemd/system/cloud-init.target"
|
||||
CLOUD_SYSTEM_TARGET="/lib/systemd/system/cloud-init.target"
|
||||
{% endif %}
|
||||
{% if variant in ["almalinux", "centos", "cloudlinux", "eurolinux", "fedora",
|
||||
- "miraclelinux", "openEuler", "OpenCloudOS", "openmandriva", "rhel", "rocky", "TencentOS", "virtuozzo"] %}
|
||||
+ "miraclelinux", "openeuler", "OpenCloudOS", "openmandriva", "rhel", "rocky", "TencentOS", "virtuozzo"] %}
|
||||
dsidentify="/usr/libexec/cloud-init/ds-identify"
|
||||
{% else %}
|
||||
dsidentify="/usr/lib/cloud-init/ds-identify"
|
||||
diff --git a/systemd/cloud-init.service.tmpl b/systemd/cloud-init.service.tmpl
|
||||
index 1b1f9a8..c7a7c64 100644
|
||||
--- a/systemd/cloud-init.service.tmpl
|
||||
+++ b/systemd/cloud-init.service.tmpl
|
||||
@@ -13,7 +13,7 @@ After=systemd-networkd-wait-online.service
|
||||
After=networking.service
|
||||
{% endif %}
|
||||
{% if variant in ["almalinux", "centos", "cloudlinux", "eurolinux", "fedora",
|
||||
- "miraclelinux", "openEuler", "OpenCloudOS", "openmandriva", "rhel", "rocky",
|
||||
+ "miraclelinux", "openeuler", "OpenCloudOS", "openmandriva", "rhel", "rocky",
|
||||
"suse", "TencentOS", "virtuozzo"] %}
|
||||
|
||||
After=network.service
|
||||
diff --git a/tests/unittests/test_cli.py b/tests/unittests/test_cli.py
|
||||
index e3fed41..2f031ee 100644
|
||||
--- a/tests/unittests/test_cli.py
|
||||
+++ b/tests/unittests/test_cli.py
|
||||
@@ -246,7 +246,7 @@ class TestCLI:
|
||||
"**Supported distros:** almalinux, alpine, centos, "
|
||||
"cloudlinux, cos, debian, eurolinux, fedora, freebsd, "
|
||||
"mariner, miraclelinux, "
|
||||
- "openbsd, openEuler, OpenCloudOS, openmandriva, "
|
||||
+ "openbsd, openeuler, OpenCloudOS, openmandriva, "
|
||||
"opensuse, opensuse-microos, opensuse-tumbleweed, "
|
||||
"opensuse-leap, photon, rhel, rocky, sle_hpc, "
|
||||
"sle-micro, sles, TencentOS, ubuntu, virtuozzo",
|
||||
diff --git a/tools/render-cloudcfg b/tools/render-cloudcfg
|
||||
index 6551875..b21fdee 100755
|
||||
--- a/tools/render-cloudcfg
|
||||
+++ b/tools/render-cloudcfg
|
||||
@@ -25,7 +25,7 @@ def main():
|
||||
"miraclelinux",
|
||||
"netbsd",
|
||||
"openbsd",
|
||||
- "openEuler",
|
||||
+ "openeuler",
|
||||
"OpenCloudOS",
|
||||
"openmandriva",
|
||||
"photon",
|
||||
--
|
||||
2.27.0
|
||||
|
||||
Binary file not shown.
BIN
cloud-init-23.4.1.tar.gz
Normal file
BIN
cloud-init-23.4.1.tar.gz
Normal file
Binary file not shown.
@ -1,6 +1,6 @@
|
||||
Name: cloud-init
|
||||
Version: 23.2.2
|
||||
Release: 6
|
||||
Version: 23.4.1
|
||||
Release: 1
|
||||
Summary: the defacto multi-distribution package that handles early initialization of a cloud instance.
|
||||
License: ASL 2.0 or GPLv3
|
||||
URL: http://launchpad.net/cloud-init
|
||||
@ -9,17 +9,11 @@ Source0: https://launchpad.net/%{name}/trunk/%{version}/+download/%{name}-%{vers
|
||||
Source1: cloud-init-tmpfiles.conf
|
||||
|
||||
Patch0: cloud-init-22.1-no-override-default-network.patch
|
||||
Patch1: bugfix-cloud-init-add-os-support.patch
|
||||
Patch2: bugfix-sort-requirements.patch
|
||||
Patch3: add-variable-to-forbid-tmp-dir.patch
|
||||
Patch4: Fix-the-error-level-logs-displayed-for-the-cloud-init-local-service.patch
|
||||
Patch5: cloud-init-23.2.2-nm-controlled.patch
|
||||
Patch5: Do-not-write-NM_CONTROLLED-no-in-generated-interface-config.patch
|
||||
Patch6: delete-config-nopasswd-all.patch
|
||||
|
||||
Patch6000: backport-fix-Don-t-loosen-the-permissions-of-the-log-file-462.patch
|
||||
|
||||
Patch9000: do-not-generate-dsa.patch
|
||||
|
||||
BuildRequires: pkgconfig(systemd) python3-devel python3-setuptools systemd
|
||||
BuildRequires: iproute python3-configobj python3-responses
|
||||
BuildRequires: python3-jinja2 python3-jsonpatch python3-jsonschema
|
||||
@ -30,8 +24,8 @@ BuildRequires: python3-pytest-mock
|
||||
|
||||
Requires: e2fsprogs iproute python3-libselinux net-tools python3-policycoreutils
|
||||
Requires: procps python3-configobj python3-jinja2 python3-jsonpatch xfsprogs
|
||||
Requires: python3-jsonschema python3-oauthlib python3-prettytable util-linux
|
||||
Requires: python3-pyserial python3-pyyaml python3-requests python3-six shadow
|
||||
Requires: python3-jsonschema python3-oauthlib python3-netifaces util-linux
|
||||
Requires: python3-pyserial python3-pyyaml python3-requests shadow
|
||||
%{?systemd_requires}
|
||||
|
||||
BuildArch: noarch
|
||||
@ -54,7 +48,7 @@ sed -i 's/\/etc\/redhat-release/\/etc\/%{_vendor}-release/g' setup.py
|
||||
|
||||
%install
|
||||
%py3_install -- --init-system=systemd
|
||||
python3 tools/render-cloudcfg --variant openeuler > %{buildroot}/%{_sysconfdir}/cloud/cloud.cfg
|
||||
python3 tools/render-template --variant openeuler > %{buildroot}/%{_sysconfdir}/cloud/cloud.cfg
|
||||
install -d %{buildroot}/var/lib/cloud
|
||||
install -d %{buildroot}/run/%{name}
|
||||
install -D -m 0644 %{SOURCE1} %{buildroot}/%{_tmpfilesdir}/%{name}.conf
|
||||
@ -125,6 +119,12 @@ fi
|
||||
%exclude /usr/share/doc/*
|
||||
|
||||
%changelog
|
||||
* Wed Jan 24 2024 shixuantong <shixuantong1@huawei.com> - 23.4.1-1
|
||||
- Type:enhancement
|
||||
- CVE:NA
|
||||
- SUG:NA
|
||||
- DESC:upgrade version to 23.4.1
|
||||
|
||||
* Mon Jan 15 2024 shixuantong <shixuantong1@huawei.com> - 23.2.2-6
|
||||
- Type:bugfix
|
||||
- CVE:NA
|
||||
|
||||
@ -8,16 +8,17 @@ Subject: [xfusion]cloud-init:delete "ALL=(ALL) NOPASSWD:ALL" in cloud.cfg.tmpl
|
||||
1 file changed, 1 deletion(-)
|
||||
|
||||
diff --git a/config/cloud.cfg.tmpl b/config/cloud.cfg.tmpl
|
||||
index 39e36dd..cbf91ac 100644
|
||||
index de0bf7b..f096595 100644
|
||||
--- a/config/cloud.cfg.tmpl
|
||||
+++ b/config/cloud.cfg.tmpl
|
||||
@@ -252,7 +252,6 @@ system_info:
|
||||
{% else %}
|
||||
groups: [wheel, adm, systemd-journal]
|
||||
@@ -272,7 +272,6 @@ system_info:
|
||||
- permit nopass {{ variant }}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
- sudo: ["ALL=(ALL) NOPASSWD:ALL"]
|
||||
{% if variant == "alpine" %}
|
||||
shell: /bin/ash
|
||||
{% if variant in shells %}
|
||||
shell: {{ shells[variant] }}
|
||||
{% else %}
|
||||
--
|
||||
2.27.0
|
||||
|
||||
|
||||
@ -1,26 +0,0 @@
|
||||
From ab1a7fc06f5e6804bc44a9c55bdba197a4c89100 Mon Sep 17 00:00:00 2001
|
||||
From: shixuantong <shixuantong1@huawei.com>
|
||||
Date: Wed, 1 Nov 2023 17:21:45 +0800
|
||||
Subject: [PATCH] do not generate dsa
|
||||
|
||||
---
|
||||
config/cloud.cfg.tmpl | 3 +++
|
||||
1 file changed, 3 insertions(+)
|
||||
|
||||
diff --git a/config/cloud.cfg.tmpl b/config/cloud.cfg.tmpl
|
||||
index e686770..9a8a41d 100644
|
||||
--- a/config/cloud.cfg.tmpl
|
||||
+++ b/config/cloud.cfg.tmpl
|
||||
@@ -82,6 +82,9 @@ syslog_fix_perms: ~
|
||||
disable_vmware_customization: false
|
||||
{% endif %}
|
||||
|
||||
+# do not generate dsa
|
||||
+ssh_genkeytypes: ['rsa', 'ecdsa', 'ed25519']
|
||||
+
|
||||
# The modules that run in the 'init' stage
|
||||
cloud_init_modules:
|
||||
- migrator
|
||||
--
|
||||
2.33.0
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user