* Re: [meta-oe][scarthgap][PATCH 1/1] image-oci-unmoci: preserve file modes
[not found] ` <20260226172529.2551136-2-adrian.freihofer@siemens.com>
@ 2026-02-26 18:20 ` Bruce Ashfield
0 siblings, 0 replies; only message in thread
From: Bruce Ashfield @ 2026-02-26 18:20 UTC (permalink / raw)
To: AdrianF; +Cc: meta-virtualization
merged.
Bruce
In message: [meta-oe][scarthgap][PATCH 1/1] image-oci-unmoci: preserve file modes
on 26/02/2026 AdrianF wrote:
> From: Bruce Ashfield <bruce.ashfield@gmail.com>
>
> Based on the following patch:
>
> Subject: [meta-virtualization][PATCH] image-oci-umoci: preserve file modes in rootfs
> From: "Florian Wickert via lists.yoctoproject.org" <FlorianWickert=gmail.com@lists.yoctoproject.org>
>
> cp does not preserve file modes by default.
> This will break sudo (among others) which needs the suid flag to do its
> work.
>
> This patch adds the --preserve=mode flag to the cp call to fix this.
>
> Signed-off-by: Florian Wickert <FlorianWickert@gmail.com>
>
> Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
> Signed-off-by: Adrian Freihofer <adrian.freihofer@siemens.com>
> ---
> classes/image-oci-umoci.inc | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/classes/image-oci-umoci.inc b/classes/image-oci-umoci.inc
> index c77750fb..9bd154fb 100644
> --- a/classes/image-oci-umoci.inc
> +++ b/classes/image-oci-umoci.inc
> @@ -50,7 +50,7 @@ IMAGE_CMD:oci() {
>
> bbdebug 1 "OCI: populating rootfs"
> bbdebug 1 "OCI: cp -r ${IMAGE_ROOTFS}/* $image_bundle_name/rootfs/"
> - cp -r ${IMAGE_ROOTFS}/* $image_bundle_name/rootfs
> + cp -r -a --no-preserve=ownership ${IMAGE_ROOTFS}/* $image_bundle_name/rootfs
>
> bbdebug 1 "OCI: umoci repack --image $image_name:${OCI_IMAGE_TAG} $image_bundle_name"
> umoci repack --image $image_name:${OCI_IMAGE_TAG} $image_bundle_name
> --
> 2.53.0
>
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2026-02-26 18:21 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <20260226172529.2551136-1-adrian.freihofer@siemens.com>
[not found] ` <20260226172529.2551136-2-adrian.freihofer@siemens.com>
2026-02-26 18:20 ` [meta-oe][scarthgap][PATCH 1/1] image-oci-unmoci: preserve file modes Bruce Ashfield
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox