Files
integ/ostree/initramfs-ostree/debian/all/patches/0005-init-ostree-install.sh-break-hardlinks-in-var.patch
Robert Church 69f8cdcf4a Add Trixie build support for ostree pkgs
This introduces some packages for a trixie specific build.

Changes include:
 - Add debian_trixie_pkg_dirs_std based off of debian_pkg_dirs and
   comment out all packages except for:
   - ostree/initramfs-ostree
   - ostree/mttyexec
   - ostree/ostree
   - ostree/ostree-upgrade-mgr
 - Move ostree/initramfs-ostree/debian to
   ostree/initramfs-ostree/debian/all
 - Move ostree/mttyexec/debian to ostree/mttyexec/debian/all
 - Move ostree/ostree/debian to ostree/ostree/debian/all
 - Move ostree/ostree-upgrade-mgr/debian to
   ostree/ostree-upgrade-mgr/debian/all

Test Plan:
 - PASS: bullseye: stx-init-env --rebuild, downloader, build-pkgs -a,
   build-image
 - PASS: trixie: stx-init-env --rebuild, downloader, build-pkgs -a,
   build-image

NOTE: build-image for trixie fails, but further integration is required.
      At this point it doesn't appear to be tooling related

Prototype: Concurrent Builds in master

Change-Id: I515a4eeb88f338091ca60e55a6b47f6ef4c21607
Depends-On: https://review.opendev.org/c/starlingx/root/+/946813
Story: NNNNNNN
Task: NNNNN
Signed-off-by: Robert Church <robert.church@windriver.com>
Signed-off-by: Scott Little <scott.little@windriver.com>
2025-07-09 14:58:10 -04:00

40 lines
1.7 KiB
Diff

From: Zhang Xiao <xiao.zhang@windriver.com>
Date: Sat, 6 Aug 2022 12:39:16 +0000
Subject: init-ostree-install.sh: break hardlinks in /var
Here the root filesystem is managed by OSTree. OSTree is designed to
manage/deploy read-only filesystem. For read-only filesystem, hardlink
all files with same content is safe and can save disk space. It is a
good principle for readonly folders like /bin, /lib and so on. While
"/var" is somehow special that it is designed to store variable data
files, it can not be read-only, it must be read-write. Files in
"/var" should not be hardlinked together like other folders, break
them to make it.
Do the same for /usr/homedirs/home as it gets mounted at /var/home
at runtime.
Signed-off-by: Zhang Xiao <xiao.zhang@windriver.com>
---
init-ostree-install.sh | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/init-ostree-install.sh b/init-ostree-install.sh
index befeac7..46a0c08 100644
--- a/init-ostree-install.sh
+++ b/init-ostree-install.sh
@@ -1480,11 +1480,11 @@ else
mount -o $mount_flags LABEL=fluxdata /var1
fi
if [ -d ${PHYS_SYSROOT}/ostree/1/var ] ; then
- tar -C ${PHYS_SYSROOT}/ostree/1/var/ --xattrs --xattrs-include='*' -cf - . | \
+ tar -C ${PHYS_SYSROOT}/ostree/1/var/ --hard-dereference --xattrs --xattrs-include='*' -cf - . | \
tar --xattrs --xattrs-include='*' -xf - -C /var1 2> /dev/null
fi
if [ -d ${PHYS_SYSROOT}/ostree/1/usr/homedirs/home ] ; then
- tar -C ${PHYS_SYSROOT}/ostree/1/usr/homedirs/home --xattrs --xattrs-include='*' -cf - . | \
+ tar -C ${PHYS_SYSROOT}/ostree/1/usr/homedirs/home --hard-dereference --xattrs --xattrs-include='*' -cf - . | \
tar --xattrs --xattrs-include='*' -xf - -C /var1/home 2> /dev/null
fi