Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ All local `just` targets run BuildStream inside the FSDK `bst2` container via `j
| `just build-image` / `just export-image` | Build and export the release image set to `dist/diskless/`. |
| `just dogfood` / `just dogfood-check` | Boot `dist/diskless/` diskless in QEMU with Secure Boot (interactive / headless probe). |
| `just dogfood-install NEXT=<dir>` | QEMU end-to-end: diskless boot, install to disk, boot it, then A/B update to NEXT. |
| `just publish-oci REF [DIR] [PLAIN_HTTP]` | Push `dist/diskless/` as an ORAS OCI artifact tagged `<version>,latest` (one layer per file). |
| `just publish-oci REF [DIR] [PLAIN_HTTP]` | Push `dist/diskless/` as an ORAS OCI artifact tagged `<version>,latest` (one layer per file). Local rehearsal; CI publishes via `scripts/publish-release.sh`. |
| `just build-sysext` / `just export-sysext` | Build and export the k0s and KubeStellar `systemd-sysext` images. |
| `just build-zfs-sysext` / `just export-zfs-sysext` | Build and export the OpenZFS `systemd-sysext`. |

Expand Down
7 changes: 7 additions & 0 deletions Justfile
Original file line number Diff line number Diff line change
Expand Up @@ -147,11 +147,16 @@ dogfood-installer:

# REF=ghcr.io/<owner>/bluefin-server or <registry-host>:30500/bluefin-server
# (PLAIN_HTTP=1); log in with podman login first. One layer per file.
# Local rehearsal only: releases are published by scripts/publish-release.sh
# from .github/workflows/build.yml, which also verifies the pushed manifest
# against the local files. This recipe pushes the same artifact type,
# annotations and layout, and nothing else.
# Publish an image set as an ORAS OCI artifact tagged <version> and latest.
[group('diskless')]
publish-oci REF DIR="dist/diskless" PLAIN_HTTP="0":
#!/usr/bin/env bash
set -euo pipefail
revision="$(git rev-parse HEAD)"
cd "{{DIR}}"
uki="$(ls bluefin-server-netboot_*.efi)"
ver="${uki#bluefin-server-netboot_}"; ver="${ver%.efi}"
Expand All @@ -164,6 +169,8 @@ publish-oci REF DIR="dist/diskless" PLAIN_HTTP="0":
{{oras_image}} push "${extra[@]}" \
--artifact-type application/vnd.projectbluefin.server.release.v1 \
--annotation "org.opencontainers.image.version=${ver}" \
--annotation "org.opencontainers.image.source=${GITHUB_SERVER_URL:-https://github.com}/${GITHUB_REPOSITORY:-projectbluefin/server}" \
--annotation "org.opencontainers.image.revision=${revision}" \
"{{REF}}:${ver},latest" "${files[@]}"

# Boot dist/diskless/ in QEMU with Secure Boot, pulling /usr over HTTP.
Expand Down
4 changes: 3 additions & 1 deletion docs/skills/ddi-installer.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,9 @@ GPT partition label with room to spare):

A release publishes this directory as-is (GitHub Release `v<ver>` plus an ORAS
OCI artifact); see the `release` job in [ci-tooling.md](ci-tooling.md).
`just publish-oci REF [DIR] [PLAIN_HTTP]` pushes the same artifact locally.
`just publish-oci REF [DIR] [PLAIN_HTTP]` pushes the same artifact locally, as
a rehearsal; CI publishes through `scripts/publish-release.sh`, which also
verifies the pushed manifest against the local files.

The /usr image itself is built by `oci/bluefin-server-usr.bst` with an offline
`systemd-repart`: an erofs partition (`bluefin_usr_<ver>`) plus its dm-verity
Expand Down
16 changes: 12 additions & 4 deletions docs/skills/systemd-sysupdate-verification.md
Original file line number Diff line number Diff line change
Expand Up @@ -113,10 +113,18 @@ tell a human or a policy engine which commit and workflow run produced it.
OpenZFS sysext payloads. It lists one SPDX package per source (name,
version, download URL, source kind). Build-only elements such as the
signing keys are not runtime dependencies of that payload and never
appear. The image element stamps `creationInfo.created` and ships it as
`bluefin-server_<ver>.spdx.json`, listed in `SHA256SUMS`, so the GPG
signature covers it too. No transfer matches it, so nodes never download it.
- **Publishing.** `scripts/publish-release.sh` is the only publish path.
appear. SPDX requires a `creationInfo.created`, which the plugin leaves to
the build, so the image element stamps it from `SOURCE_DATE_EPOCH`. The
build runs in a BuildStream sandbox that fixes `SOURCE_DATE_EPOCH` to
BuildStream's own default (1321009871), so the field always reads
`2011-11-11T11:11:11Z`: it is a reproducibility placeholder, not a build
time. Use the SLSA provenance attestation (or the release tag) for when a
set was built. The SBOM ships as `bluefin-server_<ver>.spdx.json`, listed
in `SHA256SUMS`, so the GPG signature covers it too. No transfer matches
it, so nodes never download it.
- **Publishing.** In CI, `scripts/publish-release.sh` is the only publish
path (`just publish-oci` pushes to a local or personal registry for
rehearsal and runs none of the script's checks).
`verify` checks what nodes will check (`gpgv` against the keyring, every
`SHA256SUMS` entry present and matching), plus: every published file is
listed, every file name carries the release version, and the SBOM is valid
Expand Down
4 changes: 4 additions & 0 deletions elements/oci/bluefin-server-image.bst
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,10 @@ config:
# SPDX requires a creation time, which the plugin leaves to the build,
# and unique SPDXIDs: FSDK bootstrap elements reached through two
# junction paths are collected twice, as identical packages.
# SOURCE_DATE_EPOCH is BuildStream's fixed sandbox default (1321009871),
# so created is always 2011-11-11T11:11:11Z. That keeps the SBOM bit
# identical across rebuilds; the real build time lives in the SLSA
# provenance attestation, not here.
jq --arg created "$(date -u -d "@${SOURCE_DATE_EPOCH}" +%Y-%m-%dT%H:%M:%SZ)" \
'.creationInfo.created = $created
| .packages |= unique_by(.SPDXID)
Expand Down
4 changes: 3 additions & 1 deletion elements/oci/bluefin-server-sbom.bst
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,9 @@ description: |
oci/*-sysext.bst element for its own local sources (units,
extension-release, config), and the element it stages them from.

oci/bluefin-server-image.bst stamps creationInfo.created and ships the
oci/bluefin-server-image.bst stamps creationInfo.created from the
sandbox's fixed SOURCE_DATE_EPOCH (always 2011-11-11T11:11:11Z, a
reproducibility placeholder rather than a build time) and ships the
result as bluefin-server_<ver>.spdx.json inside the signed SHA256SUMS.

(@):
Expand Down