From c8030f1a241f813cc56841ed4b54726dd1583d88 Mon Sep 17 00:00:00 2001 From: Enderson Maia Date: Wed, 17 Apr 2024 13:26:47 +0100 Subject: [PATCH 01/11] feat(22.04) add slice for crun and uidmap --- slices/crun.yaml | 13 +++++++++++++ slices/libaudit-common.yaml | 6 ++++++ slices/libaudit1.yaml | 10 ++++++++++ slices/libcap-ng0.yaml | 8 ++++++++ slices/libcap2.yaml | 8 ++++++++ slices/liblz4-1.yaml | 8 ++++++++ slices/libseccomp2.yaml | 8 ++++++++ slices/libsystemd0.yaml | 13 +++++++++++++ slices/libyajl2.yaml | 8 ++++++++ slices/uidmap.yaml | 11 +++++++++++ 10 files changed, 93 insertions(+) create mode 100644 slices/crun.yaml create mode 100644 slices/libaudit-common.yaml create mode 100644 slices/libaudit1.yaml create mode 100644 slices/libcap-ng0.yaml create mode 100644 slices/libcap2.yaml create mode 100644 slices/liblz4-1.yaml create mode 100644 slices/libseccomp2.yaml create mode 100644 slices/libsystemd0.yaml create mode 100644 slices/libyajl2.yaml create mode 100644 slices/uidmap.yaml diff --git a/slices/crun.yaml b/slices/crun.yaml new file mode 100644 index 00000000..d74c0a76 --- /dev/null +++ b/slices/crun.yaml @@ -0,0 +1,13 @@ +package: crun + +slices: + bins: + essential: + - libc6_libs + - libcap2_libs + - libseccomp2_libs + - libsystemd0_libs + - libyajl2_libs + contents: + /usr/bin/crun: + /usr/lib/*-linux-*/libcrun.a: diff --git a/slices/libaudit-common.yaml b/slices/libaudit-common.yaml new file mode 100644 index 00000000..5a068dd1 --- /dev/null +++ b/slices/libaudit-common.yaml @@ -0,0 +1,6 @@ +package: libaudit-common + +slices: + config: + contents: + /etc/libaudit.conf: diff --git a/slices/libaudit1.yaml b/slices/libaudit1.yaml new file mode 100644 index 00000000..19771ceb --- /dev/null +++ b/slices/libaudit1.yaml @@ -0,0 +1,10 @@ +package: libaudit1 + +slices: + libs: + essential: + - libc6_libs + - libaudit-common_config + - libcap-ng0_libs + contents: + /lib/*-linux-*/libaudit.so.1*: diff --git a/slices/libcap-ng0.yaml b/slices/libcap-ng0.yaml new file mode 100644 index 00000000..9b5c2c4d --- /dev/null +++ b/slices/libcap-ng0.yaml @@ -0,0 +1,8 @@ +package: libcap-ng0 + +slices: + libs: + essential: + - libc6_libs + contents: + /lib/*-linux-*/libcap-ng.so.0*: diff --git a/slices/libcap2.yaml b/slices/libcap2.yaml new file mode 100644 index 00000000..72136199 --- /dev/null +++ b/slices/libcap2.yaml @@ -0,0 +1,8 @@ +package: libcap2 + +slices: + libs: + essential: + - libc6_libs + contents: + /lib/*-linux-*/libcap.so.2*: diff --git a/slices/liblz4-1.yaml b/slices/liblz4-1.yaml new file mode 100644 index 00000000..e3f56884 --- /dev/null +++ b/slices/liblz4-1.yaml @@ -0,0 +1,8 @@ +package: liblz4-1 + +slices: + libs: + essential: + - libc6_libs + contents: + /usr/lib/*-linux-*/liblz4.so.1*: diff --git a/slices/libseccomp2.yaml b/slices/libseccomp2.yaml new file mode 100644 index 00000000..5e5ea15b --- /dev/null +++ b/slices/libseccomp2.yaml @@ -0,0 +1,8 @@ +package: libseccomp2 + +slices: + libs: + essential: + - libc6_libs + contents: + /usr/lib/*-linux-*/libseccomp.so.2*: diff --git a/slices/libsystemd0.yaml b/slices/libsystemd0.yaml new file mode 100644 index 00000000..66031f5c --- /dev/null +++ b/slices/libsystemd0.yaml @@ -0,0 +1,13 @@ +package: libsystemd0 + +slices: + libs: + essential: + - libc6_libs + - libcap2_libs + - libgcrypt20_libs + - liblz4-1_libs + - liblzma5_libs + - libzstd1_libs + contents: + /usr/lib/*-linux-*/libsystemd.so.0*: diff --git a/slices/libyajl2.yaml b/slices/libyajl2.yaml new file mode 100644 index 00000000..78e847c9 --- /dev/null +++ b/slices/libyajl2.yaml @@ -0,0 +1,8 @@ +package: libyajl2 + +slices: + libs: + essential: + - libc6_libs + contents: + /usr/lib/*-linux-*/libyajl.so.2*: diff --git a/slices/uidmap.yaml b/slices/uidmap.yaml new file mode 100644 index 00000000..23ee74cd --- /dev/null +++ b/slices/uidmap.yaml @@ -0,0 +1,11 @@ +package: uidmap + +slices: + bins: + essential: + - libc6_libs + - libselinux1_libs + - libaudit1_libs + contents: + /usr/bin/newgidmap: + /usr/bin/newuidmap: From cf3e0d79d192ac7e53bd721deb0a1bfdf9dbdc83 Mon Sep 17 00:00:00 2001 From: Enderson Maia Date: Thu, 16 May 2024 09:29:36 +0100 Subject: [PATCH 02/11] fixup! feat(22.04) add slice for crun and uidmap --- slices/libmount1.yaml | 1 - 1 file changed, 1 deletion(-) diff --git a/slices/libmount1.yaml b/slices/libmount1.yaml index 893877cc..95fe6de3 100644 --- a/slices/libmount1.yaml +++ b/slices/libmount1.yaml @@ -11,7 +11,6 @@ slices: - libselinux1_libs contents: /usr/lib/*-linux-*/libmount.so.1*: - copyright: contents: /usr/share/doc/libmount1/copyright: From dd7a42f3ba29ce8c7e657c11fc52644e2d3fb104 Mon Sep 17 00:00:00 2001 From: Enderson Maia Date: Thu, 16 May 2024 09:41:49 +0100 Subject: [PATCH 03/11] fixup! feat(22.04) add slice for crun and uidmap add copyright slice --- slices/libaudit-common.yaml | 6 ++++++ slices/libaudit1.yaml | 6 ++++++ slices/libcap-ng0.yaml | 6 ++++++ slices/libgcrypt20.yaml | 1 - slices/libgpg-error0.yaml | 1 - slices/liblz4-1.yaml | 6 ++++++ slices/libseccomp2.yaml | 6 ++++++ slices/libsystemd0.yaml | 6 ++++++ slices/libyajl2.yaml | 6 ++++++ 9 files changed, 42 insertions(+), 2 deletions(-) diff --git a/slices/libaudit-common.yaml b/slices/libaudit-common.yaml index 5a068dd1..8607f4b5 100644 --- a/slices/libaudit-common.yaml +++ b/slices/libaudit-common.yaml @@ -1,6 +1,12 @@ package: libaudit-common +essential: + - libaudit-common_copyright + slices: config: contents: /etc/libaudit.conf: + copyright: + contents: + /usr/share/doc/libaudit-common/copyright: diff --git a/slices/libaudit1.yaml b/slices/libaudit1.yaml index 19771ceb..1cec711f 100644 --- a/slices/libaudit1.yaml +++ b/slices/libaudit1.yaml @@ -1,5 +1,8 @@ package: libaudit1 +essential: + - libaudit1_copyright + slices: libs: essential: @@ -8,3 +11,6 @@ slices: - libcap-ng0_libs contents: /lib/*-linux-*/libaudit.so.1*: + copyright: + contents: + /usr/share/doc/libaudit1/copyright: diff --git a/slices/libcap-ng0.yaml b/slices/libcap-ng0.yaml index 9b5c2c4d..c6440bcd 100644 --- a/slices/libcap-ng0.yaml +++ b/slices/libcap-ng0.yaml @@ -1,8 +1,14 @@ package: libcap-ng0 +essential: + - libcap-ng0_copyright + slices: libs: essential: - libc6_libs contents: /lib/*-linux-*/libcap-ng.so.0*: + copyright: + contents: + /usr/share/doc/libcap-ng0/copyright: diff --git a/slices/libgcrypt20.yaml b/slices/libgcrypt20.yaml index 9fa95b5e..0d4e0c53 100644 --- a/slices/libgcrypt20.yaml +++ b/slices/libgcrypt20.yaml @@ -11,7 +11,6 @@ slices: - libgpg-error0_libs contents: /usr/lib/*-linux-*/libgcrypt.so.20*: - copyright: contents: /usr/share/doc/libgcrypt20/copyright: diff --git a/slices/libgpg-error0.yaml b/slices/libgpg-error0.yaml index 847ff674..64ed58dc 100644 --- a/slices/libgpg-error0.yaml +++ b/slices/libgpg-error0.yaml @@ -11,7 +11,6 @@ slices: - libc6_libs contents: /lib/*-linux-*/libgpg-error.so.0*: - copyright: contents: /usr/share/doc/libgpg-error0/copyright: diff --git a/slices/liblz4-1.yaml b/slices/liblz4-1.yaml index e3f56884..0e254fca 100644 --- a/slices/liblz4-1.yaml +++ b/slices/liblz4-1.yaml @@ -1,8 +1,14 @@ package: liblz4-1 +essential: + - liblz4-1_copyright + slices: libs: essential: - libc6_libs contents: /usr/lib/*-linux-*/liblz4.so.1*: + copyright: + contents: + /usr/share/doc/liblz4-1/copyright: diff --git a/slices/libseccomp2.yaml b/slices/libseccomp2.yaml index 5e5ea15b..81ef77e3 100644 --- a/slices/libseccomp2.yaml +++ b/slices/libseccomp2.yaml @@ -1,8 +1,14 @@ package: libseccomp2 +essential: + - libseccomp2_copyright + slices: libs: essential: - libc6_libs contents: /usr/lib/*-linux-*/libseccomp.so.2*: + copyright: + contents: + /usr/share/doc/libseccomp2/copyright: diff --git a/slices/libsystemd0.yaml b/slices/libsystemd0.yaml index 66031f5c..b5ded279 100644 --- a/slices/libsystemd0.yaml +++ b/slices/libsystemd0.yaml @@ -1,5 +1,8 @@ package: libsystemd0 +essential: + - libsystemd0_copyright + slices: libs: essential: @@ -11,3 +14,6 @@ slices: - libzstd1_libs contents: /usr/lib/*-linux-*/libsystemd.so.0*: + copyright: + contents: + /usr/share/doc/libsystemd0/copyright: diff --git a/slices/libyajl2.yaml b/slices/libyajl2.yaml index 78e847c9..e5b9e985 100644 --- a/slices/libyajl2.yaml +++ b/slices/libyajl2.yaml @@ -1,8 +1,14 @@ package: libyajl2 +essential: + - libyajl2_copyright + slices: libs: essential: - libc6_libs contents: /usr/lib/*-linux-*/libyajl.so.2*: + copyright: + contents: + /usr/share/doc/libyajl2/copyright: From 2685f4c87541c18618c4e7863cb32cf2d8e34703 Mon Sep 17 00:00:00 2001 From: Enderson Maia Date: Thu, 16 May 2024 10:12:16 +0100 Subject: [PATCH 04/11] fixup! feat(22.04) add slice for crun and uidmap fix libcap2 --- slices/libcap2.yaml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/slices/libcap2.yaml b/slices/libcap2.yaml index 72136199..cbf31c2e 100644 --- a/slices/libcap2.yaml +++ b/slices/libcap2.yaml @@ -1,8 +1,14 @@ package: libcap2 +essential: + - libcap2_copyright + slices: libs: essential: - libc6_libs contents: /lib/*-linux-*/libcap.so.2*: + copyright: + contents: + /usr/share/doc/libcap2/copyright: From dce30f278a4e45421b67008bb8b652cf7d43d50a Mon Sep 17 00:00:00 2001 From: Enderson Maia Date: Thu, 16 May 2024 14:50:52 +0100 Subject: [PATCH 05/11] fixup! feat(22.04) add slice for crun and uidmap sort essential --- slices/libaudit1.yaml | 2 +- slices/uidmap.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/slices/libaudit1.yaml b/slices/libaudit1.yaml index 1cec711f..2ff61258 100644 --- a/slices/libaudit1.yaml +++ b/slices/libaudit1.yaml @@ -6,8 +6,8 @@ essential: slices: libs: essential: - - libc6_libs - libaudit-common_config + - libc6_libs - libcap-ng0_libs contents: /lib/*-linux-*/libaudit.so.1*: diff --git a/slices/uidmap.yaml b/slices/uidmap.yaml index 23ee74cd..0ebafde8 100644 --- a/slices/uidmap.yaml +++ b/slices/uidmap.yaml @@ -3,9 +3,9 @@ package: uidmap slices: bins: essential: + - libaudit1_libs - libc6_libs - libselinux1_libs - - libaudit1_libs contents: /usr/bin/newgidmap: /usr/bin/newuidmap: From 77b958c4482aec60776ba364ee4288018ffbf7b6 Mon Sep 17 00:00:00 2001 From: Enderson Maia Date: Mon, 20 May 2024 09:02:11 +0100 Subject: [PATCH 06/11] fixup! feat(22.04) add slice for crun and uidmap --- slices/crun.yaml | 6 ++++++ slices/uidmap.yaml | 6 ++++++ 2 files changed, 12 insertions(+) diff --git a/slices/crun.yaml b/slices/crun.yaml index d74c0a76..0a69d4b1 100644 --- a/slices/crun.yaml +++ b/slices/crun.yaml @@ -1,5 +1,8 @@ package: crun +essential: + - crun_copyright + slices: bins: essential: @@ -11,3 +14,6 @@ slices: contents: /usr/bin/crun: /usr/lib/*-linux-*/libcrun.a: + copyright: + contents: + /usr/share/doc/crun/copyright: diff --git a/slices/uidmap.yaml b/slices/uidmap.yaml index 0ebafde8..08560197 100644 --- a/slices/uidmap.yaml +++ b/slices/uidmap.yaml @@ -1,5 +1,8 @@ package: uidmap +essential: + - uidmap_copyright + slices: bins: essential: @@ -9,3 +12,6 @@ slices: contents: /usr/bin/newgidmap: /usr/bin/newuidmap: + copyright: + contents: + /usr/share/doc/uidmap/copyright: From 244dac3e0cb6bf033f55583770cd35418c31b22f Mon Sep 17 00:00:00 2001 From: Rafid Bin Mostofa Date: Mon, 12 Aug 2024 16:23:25 +0600 Subject: [PATCH 07/11] refactor: restore blank spaces --- slices/libgcrypt20.yaml | 1 + slices/libgpg-error0.yaml | 1 + slices/libmount1.yaml | 1 + 3 files changed, 3 insertions(+) diff --git a/slices/libgcrypt20.yaml b/slices/libgcrypt20.yaml index 0d4e0c53..9fa95b5e 100644 --- a/slices/libgcrypt20.yaml +++ b/slices/libgcrypt20.yaml @@ -11,6 +11,7 @@ slices: - libgpg-error0_libs contents: /usr/lib/*-linux-*/libgcrypt.so.20*: + copyright: contents: /usr/share/doc/libgcrypt20/copyright: diff --git a/slices/libgpg-error0.yaml b/slices/libgpg-error0.yaml index 64ed58dc..847ff674 100644 --- a/slices/libgpg-error0.yaml +++ b/slices/libgpg-error0.yaml @@ -11,6 +11,7 @@ slices: - libc6_libs contents: /lib/*-linux-*/libgpg-error.so.0*: + copyright: contents: /usr/share/doc/libgpg-error0/copyright: diff --git a/slices/libmount1.yaml b/slices/libmount1.yaml index 95fe6de3..893877cc 100644 --- a/slices/libmount1.yaml +++ b/slices/libmount1.yaml @@ -11,6 +11,7 @@ slices: - libselinux1_libs contents: /usr/lib/*-linux-*/libmount.so.1*: + copyright: contents: /usr/share/doc/libmount1/copyright: From f05d907c59c2f8aded155f3671722e369807b302 Mon Sep 17 00:00:00 2001 From: Rafid Bin Mostofa Date: Mon, 12 Aug 2024 16:24:53 +0600 Subject: [PATCH 08/11] fix: add crun_libs slice --- slices/crun.yaml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/slices/crun.yaml b/slices/crun.yaml index 0a69d4b1..1f5b3e82 100644 --- a/slices/crun.yaml +++ b/slices/crun.yaml @@ -6,6 +6,7 @@ essential: slices: bins: essential: + - crun_libs - libc6_libs - libcap2_libs - libseccomp2_libs @@ -13,6 +14,8 @@ slices: - libyajl2_libs contents: /usr/bin/crun: + libs: + contents: /usr/lib/*-linux-*/libcrun.a: copyright: contents: From 2c43d514c78dad7db3c95f342e455990446f3ec2 Mon Sep 17 00:00:00 2001 From: Rafid Bin Mostofa Date: Mon, 12 Aug 2024 16:28:26 +0600 Subject: [PATCH 09/11] test(spread): add smoke test for crun --- tests/spread/integration/crun/task.yaml | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 tests/spread/integration/crun/task.yaml diff --git a/tests/spread/integration/crun/task.yaml b/tests/spread/integration/crun/task.yaml new file mode 100644 index 00000000..b0e3448b --- /dev/null +++ b/tests/spread/integration/crun/task.yaml @@ -0,0 +1,5 @@ +summary: Smoke test for crun + +execute: | + rootfs="$(install-slices crun_bins)" + chroot "$rootfs" crun --version From c801dd4e88a86fefd99fdbe9873bc91a1587a9c5 Mon Sep 17 00:00:00 2001 From: Rafid Bin Mostofa Date: Mon, 12 Aug 2024 16:57:25 +0600 Subject: [PATCH 10/11] Revert "test(spread): add smoke test for crun" This reverts commit 2c43d514c78dad7db3c95f342e455990446f3ec2. --- tests/spread/integration/crun/task.yaml | 5 ----- 1 file changed, 5 deletions(-) delete mode 100644 tests/spread/integration/crun/task.yaml diff --git a/tests/spread/integration/crun/task.yaml b/tests/spread/integration/crun/task.yaml deleted file mode 100644 index b0e3448b..00000000 --- a/tests/spread/integration/crun/task.yaml +++ /dev/null @@ -1,5 +0,0 @@ -summary: Smoke test for crun - -execute: | - rootfs="$(install-slices crun_bins)" - chroot "$rootfs" crun --version From e3d993c3b3d86fa5556bd38a543de7e6e68532b1 Mon Sep 17 00:00:00 2001 From: Cristovao Cordeiro Date: Fri, 27 Sep 2024 17:06:40 +0200 Subject: [PATCH 11/11] test: add tests for crun --- tests/spread/integration/crun/task.yaml | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 tests/spread/integration/crun/task.yaml diff --git a/tests/spread/integration/crun/task.yaml b/tests/spread/integration/crun/task.yaml new file mode 100644 index 00000000..42d1c0c6 --- /dev/null +++ b/tests/spread/integration/crun/task.yaml @@ -0,0 +1,14 @@ +summary: Integration tests for crun + +execute: | + rootfs="$(install-slices crun_bins)" + + # crun needs proc mounted + mkdir "${rootfs}"/proc + mount --bind /proc "${rootfs}"/proc + + chroot "$rootfs" crun --help + chroot "$rootfs" crun list + + chroot "$rootfs" crun spec + test -f "$rootfs"/config.json