Skip to content

Integrate meta-seco-clea-os/davc/overlay

Commit: clea-os/layers/seco/meta-seco-clea-os@1e2ebc61

[CLASS][CLEA-OS] Fix setting only for overlay feature

Use option --no-fstab-update only if the current disk layout is using the overlay feature.

Signed-off-by: Davide Cardillo davide.cardillo@seco.com

--

Commit: clea-os/layers/seco/meta-seco-clea-os@24c36a6e

[INITRAMFS] Fix log message in init-boot.sh

Replace an error log message with an info log message in the init-boot.sh script.

Signed-off-by: Davide Cardillo davide.cardillo@seco.com

--

Commit: clea-os/layers/seco/meta-seco-clea-os@a27cfbc2

[CLASS][OVERLAY] Improved handling of subfolders in overlayfs rootfs

This commit enhances the handling of subfolders in the overlay filesystem rootfs.

It ensures that if a folder does not exist in the IMAGE_ROOTFS, it checks for the existence of its parent folder before creating it in the overlayfs rootfs.

This prevents unnecessary warnings and improves the robustness of the overlay filesystem setup, giving the possibility to have folders in the upper layer that are not present in the lower layer (the only requirement is that the parent folder exists).

Signed-off-by: Davide Cardillo davide.cardillo@seco.com

--

Commit: clea-os/layers/seco/meta-seco-clea-os@9154a0d7

[CLASS][OVERLAY] Remove not used variables

Signed-off-by: Davide Cardillo davide.cardillo@seco.com

--

Commit: clea-os/layers/seco/meta-seco-clea-os@750f0aa9

[INITRAMFS] Fix type of variable

Signed-off-by: Davide Cardillo davide.cardillo@seco.com

--

Commit: clea-os/layers/seco/meta-seco-clea-os@92a5d767

[DISTRO-FEATURE] Reword feature clea-os-rootfs-ro to clea-os-rootfs-squashfs-ro

This is to avoid misunderstandings with Poky's read-only-rootfs that creates read-only rootfs non-SquashFS-based. Changed in something explicitly saying that it will be done with SquashFS with the possibly in the future we will add to the configurator the possibility to create read-only filesystems in SquashFS or ext4.

Suggested by: Nicola Sparnacci nicola.sparnacci@seco.com Signed-off-by: Davide Cardillo davide.cardillo@seco.com

--

Commit: clea-os/layers/seco/meta-seco-clea-os@26385d4a

[RAUC-BUNDLE] Add support for a squashfs rootfs

The enabling of "clea-os-rootfs-ro" Clea OS DISTRO_FEATURES set the rootfs as a squashfs image. This commit adds the support for this feature in the RAUC bundle, allowing the generation of a squashfs rootfs image.

In this case, the rootfs..squashfs file is used instead of the default rootfs..ext4 file.

Signed-off-by: Davide Cardillo davide.cardillo@seco.com

--

Commit: clea-os/layers/seco/meta-seco-clea-os@a61fcf40

[RAUC] update rauc_set.sh to handle squashfs rootfs type

The current version of the script places "squashfs" as a valid rootfs type, but RAUC does not support it. This update changes the rootfs type to "raw" when "squashfs" is detected, ensuring compatibility with RAUC's requirements.

Signed-off-by: Davide Cardillo davide.cardillo@seco.com

--

Commit: clea-os/layers/seco/meta-seco-clea-os@58e36e8d

[YCONFIG] Add item for overlayFS partition

The new entry in the Yconfig system disk layout allows users to choose whether the auxiliary OverlayFS partition should be included in the image. The selection of it automatically enable the following DISTRO_FEATURE:

clea-os-overlay

Signed-off-by: Davide Cardillo davide.cardillo@seco.com

--

Commit: clea-os/layers/seco/meta-seco-clea-os@30ee5651

[YCONFIG] Add item for a squashfs root partition

The new entry in the Yconfig system disk layout allows users to choose whether the root partition should be a squashfs filesystem instead of the default ext4. The selection of it automatically enable the following DISTRO_FEATURE:

clea-os-rootfs-ro

Signed-off-by: Davide Cardillo davide.cardillo@seco.com

--

Commit: clea-os/layers/seco/meta-seco-clea-os@37e5f1c4

[INITRD] Add manageement of the overlay partition

This commit introduces the management of an overlay partition in the initrd script. It includes the logic to find the overlay partition by its type GUID, mount it, and handle the overlay root filesystem. The mounting of the various overlays is demanded to the script automatically generated by the Clea OS overlay class.

Signed-off-by: Davide Cardillo davide.cardillo@seco.com

--

Commit: clea-os/layers/seco/meta-seco-clea-os@f4648b2a

[INITRD] Make parametric the init script

Introduced the usage of file-parametric class to make parametric the init script. Present parameters are:

  • ROOTFS_TYPE: type of the rootfs, can be 'squashfs' or 'ext4'
  • OVERLAY_TYPE_GUID: type GUID of the overlay partition, default is CLEA_OS_GPT_TYPE_AUXDATA

Note: the ROOTFS_TYPE can be removed in the future if the management of the partition type of the rootfs will be present inside the init script itself. This parameter has been added inside the mount command line.

Signed-off-by: Davide Cardillo davide.cardillo@seco.com

--

Commit: clea-os/layers/seco/meta-seco-clea-os@ed6fac22

[INITRAMFS] Add function for partition ID searching

The function find_partition_id_by_type_guid has been added to the init script of the ramfs. This function allows searching for a partition by its type GUID, which is useful for identifying specific partitions in the disk layout.

find_partition_id_by_type_guid parameters:

  • device to seach into (e.g. /dev/mmcblk0)
  • type GUID to search for (e.g. 12345678-1234-1234-1234-123456789012)

Signed-off-by: Davide Cardillo davide.cardillo@seco.com

--

Commit: clea-os/layers/seco/meta-seco-clea-os@a2911fa7

[INITARAMFS] Add tools for the management of the partitions

Added tools needed to manage the partitions of the disk layout. Those are useful also for the function will be introduced next to automatically retrieve the partition ID given the type GUID.

Signed-off-by: Davide Cardillo davide.cardillo@seco.com

--

Commit: clea-os/layers/seco/meta-seco-clea-os@9b209f3e

[DISK-LAYOUT] Add support of squashfs for rootfs

Introduced support for squashfs rootfs in the clea-os-distro.bbclass. In this way, the rootfs can be built as a read-only filesystem when the DISTRO_FEATURES clea-os-rootfs-ro is enabled.

In according to the present structure, the following variables are used:

  • ROOTFS_TYPE: Defines the type of the root filesystem, either squashfs or ext4.
  • ROOTFS_LABEL: Defines the label of the root filesystem. If clea-os-rootfs-ro is enabled, it will be empty, otherwise it will be set to '--label=rootfs'. This is because a squashfs filesystem can not have a label, while ext4 can.

Signed-off-by: Davide Cardillo davide.cardillo@seco.com

--

Commit: clea-os/layers/seco/meta-seco-clea-os@3ce270e2

[WKS] Remove update of fstab by WKS plugin

the flag --no-fstab-update has been added to the variable WIC_CREATE_EXTRA_ARGS. This avoids the update of fstab by the WKS plugin. This is because the introduction a additional partitions like the one dedicated to the overlay, causes the WKS plugin to update the fstab with the new partition, which is not desired in this case (the overlay partition is managed ad used by the initrd and doesn't nedd to be modunted).

Signed-off-by: Davide Cardillo davide.cardillo@seco.com

--

Commit: clea-os/layers/seco/meta-seco-clea-os@13de855e

[DISK-LAYOUT] Add AUX partition set for overlay support

The WKS_AUX_PARTITION_LAYOUT variable has been added to the WKS file of Clea OS.

This variable defines all auxiliary partitions that complement the standard disk layout (i.e., rootfs and bootfs). The first partition in this set is the overlay partition, whose inclusion is controlled by the clea-os-overlay DISTRO_FEATURE.

Signed-off-by: Davide Cardillo davide.cardillo@seco.com

--

Commit: clea-os/layers/seco/meta-seco-clea-os@6c9948a6

[DISK-LAYOUT][WIC] Add new WKS class for overlay filesystem

This class creates a new partition using the content of the overlay folder presents into the rootfs build directory. This mains that it work in conjunction with the overlay feature of Clea OS.

Added a new WICVARS: OVERLAY_ROOTFS

Signed-off-by: Davide Cardillo davide.cardillo@seco.com

--

Commit: clea-os/layers/seco/meta-seco-clea-os@41a9b701

[DISK-LAYOUT] Add new GPT type GUID for overlay partition

This new GUID will be used to identify the overlay partition in the disk layout. The GUID is defined as follows:

0xA2B3C4D5-E6F7-8901-2345-6789ABCDEF01

Useful specially into the ramdisk image, where the overlay partition is mounted and used.

Signed-off-by: Davide Cardillo davide.cardillo@seco.com

--

Commit: clea-os/layers/seco/meta-seco-clea-os@5c9898d8

[IMAGE] Introduce overlay image type in Clea OS

This commit introduces support for the overlay image type in the Clea OS image.

The image_types_overlay.bbclass is now included via the IMGCLASS variable in the clea-os-image.bbclass. Additionally, the overlay and overlay-ext4 image types are appended to the IMAGE_FSTYPES variable. These changes are conditionally applied based on the presence of the clea-os-overlay-image DISTRO_FEATURE.

The CLEA_OS_OVERLAY_FOLDERS variable is also populated to specify which folders should be included in the overlay image. Currently, it includes:

  • etc/
  • run/
  • Specific subfolders of var/ (the full var/ directory is excluded due to internal symbolic links that can cause service errors during the boot stage if fully overlaid).

Signed-off-by: Davide Cardillo davide.cardillo@seco.com

--

Commit: clea-os/layers/seco/meta-seco-clea-os@414b5bcc

[CLASS] Add new class for the management of overlay images

This is a Clea OS custom management of an additional partition for overlay images.

This class provides functionality to handle overlay images in the build process. It provides a new task do_image_overlay that creates a partition for the overlay filesystem and prepares it for use in the image. The do_image_overlay task is designed to be used in conjunction with other image tasks, allowing for the creation of images that include an overlay filesystem. It is runned after the root filesystem has been created, and adds the following steps to the image creation process:

  1. Creates a directory for the overlay filesystem overlayfs. This directory contains a list of folder names that will be used to create the overlay filesystem. That list comes form the CLEA_OS_OVERLAY_FOLDERS variable.
  2. Create a directory overlay, used to build the additional partition containing all needed files for the overlay filesystem:
    • The folder uppers, where the content fo the overlayfs is copied in;
    • The folder work, used by the overlay filesystem to manage the changes; for each item in CLEA_OS_OVERLAY_FOLDERS, a subfolder with name `workdir-<4 RANDOM DIGITS> is created;
    • The autogenerated script mount_overlay.sh. This accepts the following parameters:
      • base directory where the lower filesystem is mounted;
      • base directory where the overlay filesystem is mounted (containing the uppers and work folders); Given those parameters, the script mounts each upper directory into the lower filesystem, using the working directory for each overlay folder.

The idea is to use this script inside the initramfs to mount the overlay filesystem on top of the root filesystem, allowing for dynamic changes to the filesystem at runtime.

Signed-off-by: Davide Cardillo davide.cardillo@seco.com

Merge request reports

Loading