From 7c9b09875275fe37844726d54953faf3a0af25ba Mon Sep 17 00:00:00 2001 From: kylerankin Date: Sun, 13 Sep 2026 23:31:00 +0000 Subject: [PATCH 1/3] feat(flatcar): import upstream podman/containerd/docker sysexts, drop FSDK podman Flatcar publishes the container runtimes as systemd-sysext images per release. Import flatcar-podman, containerd-flatcar, and docker-flatcar as sha256-pinned import elements following flatcar-zfs.bst: unsquashfs each extension into the OS payload and stage the raw under /usr/lib/sysexts so systemd-sysext attaches it at runtime (podman info works on a booted image). Replace freedesktop-sdk.bst:components/podman.bst in os-stack.bst with these three sysexts, enforcing hard rule 4 (no container runtime in the base DDI). projectbluefin/server#127 Signed-off-by: kylerankin --- elements/bluefin-server/os-stack.bst | 14 +++++++--- elements/flatcar/containerd-flatcar.bst | 34 ++++++++++++++++++++++++ elements/flatcar/docker-flatcar.bst | 34 ++++++++++++++++++++++++ elements/flatcar/flatcar-podman.bst | 35 +++++++++++++++++++++++++ 4 files changed, 114 insertions(+), 3 deletions(-) create mode 100644 elements/flatcar/containerd-flatcar.bst create mode 100644 elements/flatcar/docker-flatcar.bst create mode 100644 elements/flatcar/flatcar-podman.bst diff --git a/elements/bluefin-server/os-stack.bst b/elements/bluefin-server/os-stack.bst index 074634d0..93bf2bee 100644 --- a/elements/bluefin-server/os-stack.bst +++ b/elements/bluefin-server/os-stack.bst @@ -34,6 +34,17 @@ depends: - flatcar/flatcar-zfs.bst - bluefin-server/linux-firmware-split.bst + # Container Runtime via Flatcar sysexts + # Upstream Flatcar publishes podman, containerd, and docker as systemd-sysext + # images (projectbluefin/server#127). This replaces the FSDK podman component + # below with these upstream sysexts, honoring hard rule 4 (no container + # runtime in the base DDI). Each element pins the .raw by sha256 and follows + # flatcar-zfs.bst: unsquashfs the extension into the image and stage the raw + # under /usr/lib/sysexts so systemd-sysext attaches it on a booted image. + - flatcar/flatcar-podman.bst + - flatcar/containerd-flatcar.bst + - flatcar/docker-flatcar.bst + # Filesystem resizing support for growing root/var on first boot - freedesktop-sdk.bst:components/xfsprogs.bst @@ -64,9 +75,6 @@ depends: # Reboot Coordination for Kured - bluefin-server/os-kured-hook.bst - # Container Runtime support - - freedesktop-sdk.bst:components/podman.bst - # System Management Justfile - bluefin-server/os-justfile.bst diff --git a/elements/flatcar/containerd-flatcar.bst b/elements/flatcar/containerd-flatcar.bst new file mode 100644 index 00000000..a1ef0c68 --- /dev/null +++ b/elements/flatcar/containerd-flatcar.bst @@ -0,0 +1,34 @@ +kind: manual +description: | + Import and extract the Flatcar containerd system extension (sysext). + Provides the containerd runtime and CLI, published by Flatcar as a + rootfs-included sysext (projectbluefin/server#127). The raw squashfs is also + staged under /usr/lib/sysexts so systemd-sysext attaches it at runtime. + +(@): + - include/arch.yml + - include/flatcar.yml + +build-depends: + - base/base-stack.bst + - freedesktop-sdk.bst:components/squashfs-tools.bst + +variables: + strip-binaries: "" + +sources: + - kind: remote + url: flatcar:stable/%{flatcar-board}/%{flatcar-version}/rootfs-included-sysexts/containerd-flatcar.raw + ref: 78e38344ac490004b9fa4c7da38bbfcffc393146aa990379aff7b5c09589f809 + +config: + install-commands: + - | + set -euo pipefail + + # Extract the SquashFS sysext directly into the element install root + unsquashfs -no-xattrs -f -d "%{install-root}" containerd-flatcar.raw + + # Also preserve the raw sysext image under /usr/lib/sysexts for runtime sysext usage + mkdir -p "%{install-root}/usr/lib/sysexts" + install -D -m 0644 containerd-flatcar.raw "%{install-root}/usr/lib/sysexts/containerd.raw" diff --git a/elements/flatcar/docker-flatcar.bst b/elements/flatcar/docker-flatcar.bst new file mode 100644 index 00000000..487b3af2 --- /dev/null +++ b/elements/flatcar/docker-flatcar.bst @@ -0,0 +1,34 @@ +kind: manual +description: | + Import and extract the Flatcar docker system extension (sysext). + Provides the Docker CLI and containerd-based runtime, published by Flatcar as + a rootfs-included sysext (projectbluefin/server#127). The raw squashfs is also + staged under /usr/lib/sysexts so systemd-sysext attaches it at runtime. + +(@): + - include/arch.yml + - include/flatcar.yml + +build-depends: + - base/base-stack.bst + - freedesktop-sdk.bst:components/squashfs-tools.bst + +variables: + strip-binaries: "" + +sources: + - kind: remote + url: flatcar:stable/%{flatcar-board}/%{flatcar-version}/rootfs-included-sysexts/docker-flatcar.raw + ref: 5105dfe9cfb1357fce76e0297c0285e169b1eeb47fa6edd83d5bafe697c72662 + +config: + install-commands: + - | + set -euo pipefail + + # Extract the SquashFS sysext directly into the element install root + unsquashfs -no-xattrs -f -d "%{install-root}" docker-flatcar.raw + + # Also preserve the raw sysext image under /usr/lib/sysexts for runtime sysext usage + mkdir -p "%{install-root}/usr/lib/sysexts" + install -D -m 0644 docker-flatcar.raw "%{install-root}/usr/lib/sysexts/docker.raw" diff --git a/elements/flatcar/flatcar-podman.bst b/elements/flatcar/flatcar-podman.bst new file mode 100644 index 00000000..2882399f --- /dev/null +++ b/elements/flatcar/flatcar-podman.bst @@ -0,0 +1,35 @@ +kind: manual +description: | + Import and extract the Flatcar podman system extension (sysext). + Provides the podman container CLI, replacing the FSDK podman component in the + OS payload (projectbluefin/server#127, hard rule 4: no container runtime in + the base DDI). The raw squashfs is also staged under /usr/lib/sysexts so + systemd-sysext attaches it at runtime on a booted image. + +(@): + - include/arch.yml + - include/flatcar.yml + +build-depends: + - base/base-stack.bst + - freedesktop-sdk.bst:components/squashfs-tools.bst + +variables: + strip-binaries: "" + +sources: + - kind: remote + url: flatcar:stable/%{flatcar-board}/%{flatcar-version}/flatcar-podman.raw + ref: bc8c6777ab9dee286eb1f70a1605a880fcc5199246d87f9c92f00d880194d72b + +config: + install-commands: + - | + set -euo pipefail + + # Extract the SquashFS sysext directly into the element install root + unsquashfs -no-xattrs -f -d "%{install-root}" flatcar-podman.raw + + # Also preserve the raw sysext image under /usr/lib/sysexts for runtime sysext usage + mkdir -p "%{install-root}/usr/lib/sysexts" + install -D -m 0644 flatcar-podman.raw "%{install-root}/usr/lib/sysexts/podman.raw" From b7e2f27e68d18cec4392544a08bdcad4b29d156e Mon Sep 17 00:00:00 2001 From: kylerankin Date: Mon, 14 Sep 2026 05:52:53 +0000 Subject: [PATCH 2/3] feat(flatcar): ship container sysexts as raw, not extracted (rule 4) The three Flatcar container sysexts (podman, containerd, docker) previously unsquashfs'd the extension into the base DDI, which contradicted the adjacent comment and hard rule 4 (no container runtime in the base DDI): the runtimes were extracted into the image, not merely staged. Per review option (a), drop the unsquashfs and stage only the pinned .raw under /usr/lib/sysexts so systemd-sysext attaches it on a booted image. - Remove the unsquashfs step and the now-unused squashfs-tools dep + strip-binaries var. - Update the four element descriptions + os-stack.bst comment to match. - Note the asymmetric upstream URL paths (podman flat, containerd/docker under rootfs-included-sysexts/) so the next reader doesn't re-check all six. - Add elements/** to unit-tests.yml paths so the unit suite runs on this PR (it touches only elements/). projectbluefin/server#127, #141 --- .github/workflows/unit-tests.yml | 2 ++ elements/bluefin-server/os-stack.bst | 3 +-- elements/flatcar/containerd-flatcar.bst | 20 +++++++++----------- elements/flatcar/docker-flatcar.bst | 20 +++++++++----------- elements/flatcar/flatcar-podman.bst | 20 +++++++++----------- 5 files changed, 30 insertions(+), 35 deletions(-) diff --git a/.github/workflows/unit-tests.yml b/.github/workflows/unit-tests.yml index fc4485d7..09a32ece 100644 --- a/.github/workflows/unit-tests.yml +++ b/.github/workflows/unit-tests.yml @@ -6,6 +6,7 @@ on: - '.github/scripts/**' - '.github/workflows/unit-tests.yml' - 'files/**' + - 'elements/**' - 'tests/unit/**' - 'Justfile' push: @@ -14,6 +15,7 @@ on: - '.github/scripts/**' - '.github/workflows/unit-tests.yml' - 'files/**' + - 'elements/**' - 'tests/unit/**' - 'Justfile' diff --git a/elements/bluefin-server/os-stack.bst b/elements/bluefin-server/os-stack.bst index 93bf2bee..77a6f53b 100644 --- a/elements/bluefin-server/os-stack.bst +++ b/elements/bluefin-server/os-stack.bst @@ -38,8 +38,7 @@ depends: # Upstream Flatcar publishes podman, containerd, and docker as systemd-sysext # images (projectbluefin/server#127). This replaces the FSDK podman component # below with these upstream sysexts, honoring hard rule 4 (no container - # runtime in the base DDI). Each element pins the .raw by sha256 and follows - # flatcar-zfs.bst: unsquashfs the extension into the image and stage the raw + # runtime in the base DDI). Each element pins the .raw by sha256 and stages it # under /usr/lib/sysexts so systemd-sysext attaches it on a booted image. - flatcar/flatcar-podman.bst - flatcar/containerd-flatcar.bst diff --git a/elements/flatcar/containerd-flatcar.bst b/elements/flatcar/containerd-flatcar.bst index a1ef0c68..f2a62291 100644 --- a/elements/flatcar/containerd-flatcar.bst +++ b/elements/flatcar/containerd-flatcar.bst @@ -1,9 +1,10 @@ kind: manual description: | - Import and extract the Flatcar containerd system extension (sysext). + Import the Flatcar containerd system extension (sysext). Provides the containerd runtime and CLI, published by Flatcar as a - rootfs-included sysext (projectbluefin/server#127). The raw squashfs is also - staged under /usr/lib/sysexts so systemd-sysext attaches it at runtime. + rootfs-included sysext (projectbluefin/server#127). Only the raw squashfs is + staged under /usr/lib/sysexts so systemd-sysext attaches it at runtime; the + runtime is not extracted into the base DDI (hard rule 4). (@): - include/arch.yml @@ -11,13 +12,11 @@ description: | build-depends: - base/base-stack.bst - - freedesktop-sdk.bst:components/squashfs-tools.bst - -variables: - strip-binaries: "" sources: - kind: remote + # rootfs-included-sysexts/ — podman ships flat instead. All six upstream + # permutations were checked — the other three 404. url: flatcar:stable/%{flatcar-board}/%{flatcar-version}/rootfs-included-sysexts/containerd-flatcar.raw ref: 78e38344ac490004b9fa4c7da38bbfcffc393146aa990379aff7b5c09589f809 @@ -26,9 +25,8 @@ config: - | set -euo pipefail - # Extract the SquashFS sysext directly into the element install root - unsquashfs -no-xattrs -f -d "%{install-root}" containerd-flatcar.raw - - # Also preserve the raw sysext image under /usr/lib/sysexts for runtime sysext usage + # Stage the raw squashfs sysext under /usr/lib/sysexts so systemd-sysext + # attaches it at runtime on a booted image. The runtime is not extracted + # into the base DDI (hard rule 4). mkdir -p "%{install-root}/usr/lib/sysexts" install -D -m 0644 containerd-flatcar.raw "%{install-root}/usr/lib/sysexts/containerd.raw" diff --git a/elements/flatcar/docker-flatcar.bst b/elements/flatcar/docker-flatcar.bst index 487b3af2..9b4c6ee5 100644 --- a/elements/flatcar/docker-flatcar.bst +++ b/elements/flatcar/docker-flatcar.bst @@ -1,9 +1,10 @@ kind: manual description: | - Import and extract the Flatcar docker system extension (sysext). + Import the Flatcar docker system extension (sysext). Provides the Docker CLI and containerd-based runtime, published by Flatcar as - a rootfs-included sysext (projectbluefin/server#127). The raw squashfs is also - staged under /usr/lib/sysexts so systemd-sysext attaches it at runtime. + a rootfs-included sysext (projectbluefin/server#127). Only the raw squashfs is + staged under /usr/lib/sysexts so systemd-sysext attaches it at runtime; the + runtime is not extracted into the base DDI (hard rule 4). (@): - include/arch.yml @@ -11,13 +12,11 @@ description: | build-depends: - base/base-stack.bst - - freedesktop-sdk.bst:components/squashfs-tools.bst - -variables: - strip-binaries: "" sources: - kind: remote + # rootfs-included-sysexts/ — podman ships flat instead. All six upstream + # permutations were checked — the other three 404. url: flatcar:stable/%{flatcar-board}/%{flatcar-version}/rootfs-included-sysexts/docker-flatcar.raw ref: 5105dfe9cfb1357fce76e0297c0285e169b1eeb47fa6edd83d5bafe697c72662 @@ -26,9 +25,8 @@ config: - | set -euo pipefail - # Extract the SquashFS sysext directly into the element install root - unsquashfs -no-xattrs -f -d "%{install-root}" docker-flatcar.raw - - # Also preserve the raw sysext image under /usr/lib/sysexts for runtime sysext usage + # Stage the raw squashfs sysext under /usr/lib/sysexts so systemd-sysext + # attaches it at runtime on a booted image. The runtime is not extracted + # into the base DDI (hard rule 4). mkdir -p "%{install-root}/usr/lib/sysexts" install -D -m 0644 docker-flatcar.raw "%{install-root}/usr/lib/sysexts/docker.raw" diff --git a/elements/flatcar/flatcar-podman.bst b/elements/flatcar/flatcar-podman.bst index 2882399f..5812e971 100644 --- a/elements/flatcar/flatcar-podman.bst +++ b/elements/flatcar/flatcar-podman.bst @@ -1,10 +1,11 @@ kind: manual description: | - Import and extract the Flatcar podman system extension (sysext). + Import the Flatcar podman system extension (sysext). Provides the podman container CLI, replacing the FSDK podman component in the OS payload (projectbluefin/server#127, hard rule 4: no container runtime in - the base DDI). The raw squashfs is also staged under /usr/lib/sysexts so - systemd-sysext attaches it at runtime on a booted image. + the base DDI). Only the raw squashfs is staged under /usr/lib/sysexts so + systemd-sysext attaches it at runtime on a booted image; the runtime is not + extracted into the base DDI. (@): - include/arch.yml @@ -12,13 +13,11 @@ description: | build-depends: - base/base-stack.bst - - freedesktop-sdk.bst:components/squashfs-tools.bst - -variables: - strip-binaries: "" sources: - kind: remote + # podman ships flat; containerd/docker ship under rootfs-included-sysexts/. + # All six upstream permutations were checked — the other three 404. url: flatcar:stable/%{flatcar-board}/%{flatcar-version}/flatcar-podman.raw ref: bc8c6777ab9dee286eb1f70a1605a880fcc5199246d87f9c92f00d880194d72b @@ -27,9 +26,8 @@ config: - | set -euo pipefail - # Extract the SquashFS sysext directly into the element install root - unsquashfs -no-xattrs -f -d "%{install-root}" flatcar-podman.raw - - # Also preserve the raw sysext image under /usr/lib/sysexts for runtime sysext usage + # Stage the raw squashfs sysext under /usr/lib/sysexts so systemd-sysext + # attaches it at runtime on a booted image. The runtime is not extracted + # into the base DDI (hard rule 4). mkdir -p "%{install-root}/usr/lib/sysexts" install -D -m 0644 flatcar-podman.raw "%{install-root}/usr/lib/sysexts/podman.raw" From 1d80112e1e58cd6b14953492d7905148bb504d75 Mon Sep 17 00:00:00 2001 From: castrojo Date: Fri, 18 Sep 2026 12:59:05 -0400 Subject: [PATCH 3/3] fix(flatcar): restore strip-binaries override on container sysexts The three Flatcar container sysext elements dropped `strip-binaries: ""` in b7e2f27 as an unused leftover of the removed unsquashfs step. It was not unused: it suppresses the default FSDK strip-commands, which shell out to `freedesktop-sdk-stripper`. That binary is not present in a sandbox whose only build-dep is base/base-stack.bst, so every one of the three elements failed the build with: sh: line 11: freedesktop-sdk-stripper: command not found ... failed with exitcode 127 These elements install a prebuilt squashfs blob and have nothing to strip. Restore the override, matching every other blob-installing element in the tree (flatcar-zfs.bst, flatcar-kernel.bst, k0s-bin.bst, oci/k0s-sysext.bst), and note why it is load-bearing so it is not removed again. `just validate` passes; `bst show --format '%{config}'` now reports empty strip-commands for all three elements. projectbluefin/server#127, #141 Assisted-by: Claude Opus 4.6 via GitHub Copilot Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- elements/flatcar/containerd-flatcar.bst | 5 +++++ elements/flatcar/docker-flatcar.bst | 5 +++++ elements/flatcar/flatcar-podman.bst | 5 +++++ 3 files changed, 15 insertions(+) diff --git a/elements/flatcar/containerd-flatcar.bst b/elements/flatcar/containerd-flatcar.bst index f2a62291..2af2265f 100644 --- a/elements/flatcar/containerd-flatcar.bst +++ b/elements/flatcar/containerd-flatcar.bst @@ -13,6 +13,11 @@ description: | build-depends: - base/base-stack.bst +variables: + # Disable the default FSDK strip-commands: this element installs a prebuilt + # squashfs blob, and freedesktop-sdk-stripper is not in this sandbox. + strip-binaries: "" + sources: - kind: remote # rootfs-included-sysexts/ — podman ships flat instead. All six upstream diff --git a/elements/flatcar/docker-flatcar.bst b/elements/flatcar/docker-flatcar.bst index 9b4c6ee5..e17b5eb9 100644 --- a/elements/flatcar/docker-flatcar.bst +++ b/elements/flatcar/docker-flatcar.bst @@ -13,6 +13,11 @@ description: | build-depends: - base/base-stack.bst +variables: + # Disable the default FSDK strip-commands: this element installs a prebuilt + # squashfs blob, and freedesktop-sdk-stripper is not in this sandbox. + strip-binaries: "" + sources: - kind: remote # rootfs-included-sysexts/ — podman ships flat instead. All six upstream diff --git a/elements/flatcar/flatcar-podman.bst b/elements/flatcar/flatcar-podman.bst index 5812e971..cd831a6b 100644 --- a/elements/flatcar/flatcar-podman.bst +++ b/elements/flatcar/flatcar-podman.bst @@ -14,6 +14,11 @@ description: | build-depends: - base/base-stack.bst +variables: + # Disable the default FSDK strip-commands: this element installs a prebuilt + # squashfs blob, and freedesktop-sdk-stripper is not in this sandbox. + strip-binaries: "" + sources: - kind: remote # podman ships flat; containerd/docker ship under rootfs-included-sysexts/.