SPAM: [PATCH container 3/3] tests: add tests for centos 10

Guillaume 09couplet.bitmap at icloud.com
Sun Aug 24 00:15:40 CEST 2025


Signed-off-by: Guillaume <09couplet.bitmap at icloud.com>
---
 src/test/run_setup_tests.pl                   |  4 +++
 src/test/test-centos10-001/config             |  4 +++
 .../system-connections/eth0.nmconnection.exp  |  9 ++++++
 src/test/test-centos10-001/etc/hostname.exp   |  1 +
 src/test/test-centos10-001/etc/hosts.exp      |  5 ++++
 .../test-centos10-001/etc/locale.conf.exp     |  1 +
 .../test-centos10-001/etc/rc.d/rc.sysinit     |  6 ++++
 .../test-centos10-001/etc/rc.d/rc.sysinit.exp |  6 ++++
 src/test/test-centos10-001/etc/redhat-release |  2 ++
 src/test/test-centos10-001/etc/securetty      | 23 +++++++++++++++
 src/test/test-centos10-001/etc/securetty.exp  | 28 +++++++++++++++++++
 .../systemd/system-preset/00-pve.preset.exp   |  5 ++++
 .../root/.ssh/authorized_keys.exp             |  3 ++
 src/test/test-centos10-002/config             |  6 ++++
 .../system-connections/eth0.nmconnection.exp  | 12 ++++++++
 .../system-connections/eth1.nmconnection.exp  |  9 ++++++
 .../system-connections/eth2.nmconnection.exp  | 10 +++++++
 src/test/test-centos10-002/etc/hostname.exp   |  1 +
 src/test/test-centos10-002/etc/hosts.exp      |  5 ++++
 .../test-centos10-002/etc/locale.conf.exp     |  1 +
 .../test-centos10-002/etc/rc.d/rc.sysinit     |  6 ++++
 .../test-centos10-002/etc/rc.d/rc.sysinit.exp |  6 ++++
 src/test/test-centos10-002/etc/redhat-release |  2 ++
 src/test/test-centos10-002/etc/securetty      | 23 +++++++++++++++
 src/test/test-centos10-002/etc/securetty.exp  | 28 +++++++++++++++++++
 .../systemd/system-preset/00-pve.preset.exp   |  5 ++++
 .../root/.ssh/authorized_keys.exp             |  3 ++
 27 files changed, 214 insertions(+)
 create mode 100644 src/test/test-centos10-001/config
 create mode 100644 src/test/test-centos10-001/etc/NetworkManager/system-connections/eth0.nmconnection.exp
 create mode 100644 src/test/test-centos10-001/etc/hostname.exp
 create mode 100644 src/test/test-centos10-001/etc/hosts.exp
 create mode 100644 src/test/test-centos10-001/etc/locale.conf.exp
 create mode 100644 src/test/test-centos10-001/etc/rc.d/rc.sysinit
 create mode 100644 src/test/test-centos10-001/etc/rc.d/rc.sysinit.exp
 create mode 100644 src/test/test-centos10-001/etc/redhat-release
 create mode 100644 src/test/test-centos10-001/etc/securetty
 create mode 100644 src/test/test-centos10-001/etc/securetty.exp
 create mode 100644 src/test/test-centos10-001/etc/systemd/system-preset/00-pve.preset.exp
 create mode 100644 src/test/test-centos10-001/root/.ssh/authorized_keys.exp
 create mode 100644 src/test/test-centos10-002/config
 create mode 100644 src/test/test-centos10-002/etc/NetworkManager/system-connections/eth0.nmconnection.exp
 create mode 100644 src/test/test-centos10-002/etc/NetworkManager/system-connections/eth1.nmconnection.exp
 create mode 100644 src/test/test-centos10-002/etc/NetworkManager/system-connections/eth2.nmconnection.exp
 create mode 100644 src/test/test-centos10-002/etc/hostname.exp
 create mode 100644 src/test/test-centos10-002/etc/hosts.exp
 create mode 100644 src/test/test-centos10-002/etc/locale.conf.exp
 create mode 100644 src/test/test-centos10-002/etc/rc.d/rc.sysinit
 create mode 100644 src/test/test-centos10-002/etc/rc.d/rc.sysinit.exp
 create mode 100644 src/test/test-centos10-002/etc/redhat-release
 create mode 100644 src/test/test-centos10-002/etc/securetty
 create mode 100644 src/test/test-centos10-002/etc/securetty.exp
 create mode 100644 src/test/test-centos10-002/etc/systemd/system-preset/00-pve.preset.exp
 create mode 100644 src/test/test-centos10-002/root/.ssh/authorized_keys.exp

diff --git a/src/test/run_setup_tests.pl b/src/test/run_setup_tests.pl
index 511631f..b269ffe 100755
--- a/src/test/run_setup_tests.pl
+++ b/src/test/run_setup_tests.pl
@@ -65,6 +65,10 @@ sub run_test {
             /etc/resolv.conf
             /etc/passwd
             /etc/shadow
+            /etc/NetworkManager/system-connections/eth0.nmconnection
+            /etc/NetworkManager/system-connections/eth1.nmconnection
+            /etc/NetworkManager/system-connections/eth2.nmconnection
+            /etc/NetworkManager/system-connections/eth3.nmconnection
             /etc/sysconfig/network
             /etc/sysconfig/network-scripts/ifcfg-eth0
             /etc/sysconfig/network-scripts/route-eth0
diff --git a/src/test/test-centos10-001/config b/src/test/test-centos10-001/config
new file mode 100644
index 0000000..c332df1
--- /dev/null
+++ b/src/test/test-centos10-001/config
@@ -0,0 +1,4 @@
+hostname: test1
+net0: bridge=vmbr0,name=eth0,ip=dhcp
+searchdomain: example.com
+nameserver: 127.0.0.1
diff --git a/src/test/test-centos10-001/etc/NetworkManager/system-connections/eth0.nmconnection.exp b/src/test/test-centos10-001/etc/NetworkManager/system-connections/eth0.nmconnection.exp
new file mode 100644
index 0000000..25a907d
--- /dev/null
+++ b/src/test/test-centos10-001/etc/NetworkManager/system-connections/eth0.nmconnection.exp
@@ -0,0 +1,9 @@
+[connection]
+id=eth0
+uuid=00000000-0000-0000-0000-000000000000
+type=ethernet
+interface-name=eth0
+[ipv4]
+method=auto
+dns=127.0.0.1
+dns-search=example.com
diff --git a/src/test/test-centos10-001/etc/hostname.exp b/src/test/test-centos10-001/etc/hostname.exp
new file mode 100644
index 0000000..a5bce3f
--- /dev/null
+++ b/src/test/test-centos10-001/etc/hostname.exp
@@ -0,0 +1 @@
+test1
diff --git a/src/test/test-centos10-001/etc/hosts.exp b/src/test/test-centos10-001/etc/hosts.exp
new file mode 100644
index 0000000..c85b363
--- /dev/null
+++ b/src/test/test-centos10-001/etc/hosts.exp
@@ -0,0 +1,5 @@
+# --- BEGIN PVE ---
+127.0.0.1 localhost.localnet localhost
+::1 localhost.localnet localhost
+127.0.1.1 test1.example.com test1
+# --- END PVE ---
diff --git a/src/test/test-centos10-001/etc/locale.conf.exp b/src/test/test-centos10-001/etc/locale.conf.exp
new file mode 100644
index 0000000..1ba7a89
--- /dev/null
+++ b/src/test/test-centos10-001/etc/locale.conf.exp
@@ -0,0 +1 @@
+LANG=C.utf8
\ No newline at end of file
diff --git a/src/test/test-centos10-001/etc/rc.d/rc.sysinit b/src/test/test-centos10-001/etc/rc.d/rc.sysinit
new file mode 100644
index 0000000..a98b7dd
--- /dev/null
+++ b/src/test/test-centos10-001/etc/rc.d/rc.sysinit
@@ -0,0 +1,6 @@
+# just a test
+# dummy
+
+/sbin/start_udev xxxxxxxxxxyyyyyyzzzz
+
+
diff --git a/src/test/test-centos10-001/etc/rc.d/rc.sysinit.exp b/src/test/test-centos10-001/etc/rc.d/rc.sysinit.exp
new file mode 100644
index 0000000..097907e
--- /dev/null
+++ b/src/test/test-centos10-001/etc/rc.d/rc.sysinit.exp
@@ -0,0 +1,6 @@
+# just a test
+# dummy
+
+#/sbin/start_udev xxxxxxxxxxyyyyyyzzzz
+
+
diff --git a/src/test/test-centos10-001/etc/redhat-release b/src/test/test-centos10-001/etc/redhat-release
new file mode 100644
index 0000000..cdd430d
--- /dev/null
+++ b/src/test/test-centos10-001/etc/redhat-release
@@ -0,0 +1,2 @@
+CentOS Stream release 10 (Coughlan)
+
diff --git a/src/test/test-centos10-001/etc/securetty b/src/test/test-centos10-001/etc/securetty
new file mode 100644
index 0000000..fae1648
--- /dev/null
+++ b/src/test/test-centos10-001/etc/securetty
@@ -0,0 +1,23 @@
+console
+vc/1
+vc/2
+vc/3
+vc/4
+vc/5
+vc/6
+vc/7
+vc/8
+vc/9
+vc/10
+vc/11
+tty1
+tty2
+tty3
+tty4
+tty5
+tty6
+tty7
+tty8
+tty9
+tty10
+tty11
\ No newline at end of file
diff --git a/src/test/test-centos10-001/etc/securetty.exp b/src/test/test-centos10-001/etc/securetty.exp
new file mode 100644
index 0000000..573c668
--- /dev/null
+++ b/src/test/test-centos10-001/etc/securetty.exp
@@ -0,0 +1,28 @@
+console
+vc/1
+vc/2
+vc/3
+vc/4
+vc/5
+vc/6
+vc/7
+vc/8
+vc/9
+vc/10
+vc/11
+tty1
+tty2
+tty3
+tty4
+tty5
+tty6
+tty7
+tty8
+tty9
+tty10
+tty11
+lxc/console
+lxc/tty1
+lxc/tty2
+lxc/tty3
+lxc/tty4
diff --git a/src/test/test-centos10-001/etc/systemd/system-preset/00-pve.preset.exp b/src/test/test-centos10-001/etc/systemd/system-preset/00-pve.preset.exp
new file mode 100644
index 0000000..9694e25
--- /dev/null
+++ b/src/test/test-centos10-001/etc/systemd/system-preset/00-pve.preset.exp
@@ -0,0 +1,5 @@
+# Added by PVE at create-time for first-boot configuration.
+enable container-getty at .service
+disable getty at .service
+disable sys-kernel-config.mount
+disable sys-kernel-debug.mount
diff --git a/src/test/test-centos10-001/root/.ssh/authorized_keys.exp b/src/test/test-centos10-001/root/.ssh/authorized_keys.exp
new file mode 100644
index 0000000..1cb3ec3
--- /dev/null
+++ b/src/test/test-centos10-001/root/.ssh/authorized_keys.exp
@@ -0,0 +1,3 @@
+# --- BEGIN PVE ---
+ssh-rsa ABCDEFG ABC at DEF
+# --- END PVE ---
diff --git a/src/test/test-centos10-002/config b/src/test/test-centos10-002/config
new file mode 100644
index 0000000..dcdfaeb
--- /dev/null
+++ b/src/test/test-centos10-002/config
@@ -0,0 +1,6 @@
+hostname: test1
+net0: name=eth0,hwaddr=12:22:33:44:55:66,bridge=vmbr0,ip=10.0.0.100/32,gw=11.0.0.1
+net1: name=eth1,hwaddr=22:33:44:55:66:77,bridge=vmbr1,ip6=fc00::1/64,gw6=fc00:1::ff
+net2: name=eth2,hwaddr=32:44:55:66:77:88,bridge=vmbr2,ip=192.168.0.1/24
+searchdomain: example.com
+nameserver: 127.0.0.1
diff --git a/src/test/test-centos10-002/etc/NetworkManager/system-connections/eth0.nmconnection.exp b/src/test/test-centos10-002/etc/NetworkManager/system-connections/eth0.nmconnection.exp
new file mode 100644
index 0000000..c6c5417
--- /dev/null
+++ b/src/test/test-centos10-002/etc/NetworkManager/system-connections/eth0.nmconnection.exp
@@ -0,0 +1,12 @@
+[connection]
+id=eth0
+uuid=00000000-0000-0000-0000-000000000000
+type=ethernet
+interface-name=eth0
+[ipv4]
+method=manual
+addresses=10.0.0.100/32
+gateway=11.0.0.1
+routes=11.0.0.1
+dns=127.0.0.1
+dns-search=example.com
diff --git a/src/test/test-centos10-002/etc/NetworkManager/system-connections/eth1.nmconnection.exp b/src/test/test-centos10-002/etc/NetworkManager/system-connections/eth1.nmconnection.exp
new file mode 100644
index 0000000..a99b707
--- /dev/null
+++ b/src/test/test-centos10-002/etc/NetworkManager/system-connections/eth1.nmconnection.exp
@@ -0,0 +1,9 @@
+[connection]
+id=eth1
+uuid=00000000-0000-0000-0000-000000000000
+type=ethernet
+interface-name=eth1
+[ipv6]
+method=manual
+address=fc00::1/64
+routes=fc00:1::ff
diff --git a/src/test/test-centos10-002/etc/NetworkManager/system-connections/eth2.nmconnection.exp b/src/test/test-centos10-002/etc/NetworkManager/system-connections/eth2.nmconnection.exp
new file mode 100644
index 0000000..53a6df6
--- /dev/null
+++ b/src/test/test-centos10-002/etc/NetworkManager/system-connections/eth2.nmconnection.exp
@@ -0,0 +1,10 @@
+[connection]
+id=eth2
+uuid=00000000-0000-0000-0000-000000000000
+type=ethernet
+interface-name=eth2
+[ipv4]
+method=manual
+addresses=192.168.0.1/24
+dns=127.0.0.1
+dns-search=example.com
diff --git a/src/test/test-centos10-002/etc/hostname.exp b/src/test/test-centos10-002/etc/hostname.exp
new file mode 100644
index 0000000..a5bce3f
--- /dev/null
+++ b/src/test/test-centos10-002/etc/hostname.exp
@@ -0,0 +1 @@
+test1
diff --git a/src/test/test-centos10-002/etc/hosts.exp b/src/test/test-centos10-002/etc/hosts.exp
new file mode 100644
index 0000000..e0f73bb
--- /dev/null
+++ b/src/test/test-centos10-002/etc/hosts.exp
@@ -0,0 +1,5 @@
+# --- BEGIN PVE ---
+127.0.0.1 localhost.localnet localhost
+::1 localhost.localnet localhost
+10.0.0.100 test1.example.com test1
+# --- END PVE ---
diff --git a/src/test/test-centos10-002/etc/locale.conf.exp b/src/test/test-centos10-002/etc/locale.conf.exp
new file mode 100644
index 0000000..1ba7a89
--- /dev/null
+++ b/src/test/test-centos10-002/etc/locale.conf.exp
@@ -0,0 +1 @@
+LANG=C.utf8
\ No newline at end of file
diff --git a/src/test/test-centos10-002/etc/rc.d/rc.sysinit b/src/test/test-centos10-002/etc/rc.d/rc.sysinit
new file mode 100644
index 0000000..a98b7dd
--- /dev/null
+++ b/src/test/test-centos10-002/etc/rc.d/rc.sysinit
@@ -0,0 +1,6 @@
+# just a test
+# dummy
+
+/sbin/start_udev xxxxxxxxxxyyyyyyzzzz
+
+
diff --git a/src/test/test-centos10-002/etc/rc.d/rc.sysinit.exp b/src/test/test-centos10-002/etc/rc.d/rc.sysinit.exp
new file mode 100644
index 0000000..097907e
--- /dev/null
+++ b/src/test/test-centos10-002/etc/rc.d/rc.sysinit.exp
@@ -0,0 +1,6 @@
+# just a test
+# dummy
+
+#/sbin/start_udev xxxxxxxxxxyyyyyyzzzz
+
+
diff --git a/src/test/test-centos10-002/etc/redhat-release b/src/test/test-centos10-002/etc/redhat-release
new file mode 100644
index 0000000..cdd430d
--- /dev/null
+++ b/src/test/test-centos10-002/etc/redhat-release
@@ -0,0 +1,2 @@
+CentOS Stream release 10 (Coughlan)
+
diff --git a/src/test/test-centos10-002/etc/securetty b/src/test/test-centos10-002/etc/securetty
new file mode 100644
index 0000000..fae1648
--- /dev/null
+++ b/src/test/test-centos10-002/etc/securetty
@@ -0,0 +1,23 @@
+console
+vc/1
+vc/2
+vc/3
+vc/4
+vc/5
+vc/6
+vc/7
+vc/8
+vc/9
+vc/10
+vc/11
+tty1
+tty2
+tty3
+tty4
+tty5
+tty6
+tty7
+tty8
+tty9
+tty10
+tty11
\ No newline at end of file
diff --git a/src/test/test-centos10-002/etc/securetty.exp b/src/test/test-centos10-002/etc/securetty.exp
new file mode 100644
index 0000000..573c668
--- /dev/null
+++ b/src/test/test-centos10-002/etc/securetty.exp
@@ -0,0 +1,28 @@
+console
+vc/1
+vc/2
+vc/3
+vc/4
+vc/5
+vc/6
+vc/7
+vc/8
+vc/9
+vc/10
+vc/11
+tty1
+tty2
+tty3
+tty4
+tty5
+tty6
+tty7
+tty8
+tty9
+tty10
+tty11
+lxc/console
+lxc/tty1
+lxc/tty2
+lxc/tty3
+lxc/tty4
diff --git a/src/test/test-centos10-002/etc/systemd/system-preset/00-pve.preset.exp b/src/test/test-centos10-002/etc/systemd/system-preset/00-pve.preset.exp
new file mode 100644
index 0000000..9694e25
--- /dev/null
+++ b/src/test/test-centos10-002/etc/systemd/system-preset/00-pve.preset.exp
@@ -0,0 +1,5 @@
+# Added by PVE at create-time for first-boot configuration.
+enable container-getty at .service
+disable getty at .service
+disable sys-kernel-config.mount
+disable sys-kernel-debug.mount
diff --git a/src/test/test-centos10-002/root/.ssh/authorized_keys.exp b/src/test/test-centos10-002/root/.ssh/authorized_keys.exp
new file mode 100644
index 0000000..1cb3ec3
--- /dev/null
+++ b/src/test/test-centos10-002/root/.ssh/authorized_keys.exp
@@ -0,0 +1,3 @@
+# --- BEGIN PVE ---
+ssh-rsa ABCDEFG ABC at DEF
+# --- END PVE ---
-- 
2.47.2




More information about the pve-devel mailing list