From 219b0fa3231cb31d77b0e26fdd189da88db65aa4 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 10 Nov 2026 15:16:10 +0000 Subject: [PATCH 1/2] build(deps): bump actions/checkout from 7.0.0 to 7.0.1 Bumps [actions/checkout](https://github.com/actions/checkout) from 7.0.0 to 7.0.1. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](https://github.com/actions/checkout/compare/9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0...3d3c42e5aac5ba805825da76410c181273ba90b1) --- updated-dependencies: - dependency-name: actions/checkout dependency-version: 7.0.1 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- .github/workflows/bandit.yml | 2 +- .github/workflows/black.yml | 2 +- .github/workflows/build.yml | 2 +- .github/workflows/pytests.yml | 2 +- .github/workflows/release.yml | 4 ++-- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/bandit.yml b/.github/workflows/bandit.yml index e8bf1644..95733fcc 100644 --- a/.github/workflows/bandit.yml +++ b/.github/workflows/bandit.yml @@ -16,7 +16,7 @@ jobs: build: runs-on: ubuntu-latest steps: - - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # pin@v7.0.0 + - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # pin@v7.0.1 - uses: ./.github/actions/setup - name: Simple bandit security checks run: make security diff --git a/.github/workflows/black.yml b/.github/workflows/black.yml index feab7210..d1858b73 100644 --- a/.github/workflows/black.yml +++ b/.github/workflows/black.yml @@ -6,6 +6,6 @@ jobs: lint: runs-on: ubuntu-latest steps: - - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # pin@v7.0.0 + - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # pin@v7.0.1 - uses: ./.github/actions/setup - run: make lint diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index edd15245..a7497460 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -16,7 +16,7 @@ jobs: build: runs-on: ubuntu-latest steps: - - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # pin@v7.0.0 + - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # pin@v7.0.1 - uses: ./.github/actions/setup - name: Simple poetry build no package run: make build diff --git a/.github/workflows/pytests.yml b/.github/workflows/pytests.yml index 112c5864..59d934f0 100644 --- a/.github/workflows/pytests.yml +++ b/.github/workflows/pytests.yml @@ -15,7 +15,7 @@ jobs: python_version: ["3.13", "3.14"] steps: - name: Checkout - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # pin@v7.0.0 + uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # pin@v7.0.1 with: fetch-depth: 2 diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 0b2f4548..a9ea2808 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -14,7 +14,7 @@ jobs: docs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # pin@v7.0.0 + - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # pin@v7.0.1 - uses: gardenlinux/python-gardenlinux-lib/.github/actions/setup@main - run: make docs - if: ${{ github.ref_type != 'tag' }} @@ -43,7 +43,7 @@ jobs: id: get-tag-name run: echo "tag-name=${GITHUB_REF/refs\/tags\//}" | tee -a "$GITHUB_OUTPUT" - name: Checkout commit - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # pin@v7.0.0 + uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # pin@v7.0.1 with: fetch-depth: 0 ref: ${{ steps.get-tag-name.outputs.tag-name }} From 1873a2140bd172fe4c9a7c697a49719c06b73268 Mon Sep 17 00:00:00 2001 From: Tobias Wolf Date: Tue, 17 Nov 2026 16:54:12 +0100 Subject: [PATCH 2/2] Follow OCI standard more strictly while generating an index manifest Signed-off-by: Tobias Wolf On-behalf-of: SAP --- src/gardenlinux/oci/image_manifest.py | 2 +- src/gardenlinux/oci/index.py | 13 ++++++++++++- 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/src/gardenlinux/oci/image_manifest.py b/src/gardenlinux/oci/image_manifest.py index db28edd9..fa429cd6 100644 --- a/src/gardenlinux/oci/image_manifest.py +++ b/src/gardenlinux/oci/image_manifest.py @@ -379,7 +379,7 @@ def write_metadata_file(self, manifest_file_path_name: PathLike[str] | str) -> N manifest_file_path_name = Path(manifest_file_path_name) metadata = deepcopy(empty_manifest_metadata) - metadata["mediaType"] = "application/vnd.oci.image.manifest.v1+json" + metadata["mediaType"] = IMAGE_MANIFEST_MEDIA_TYPE metadata["digest"] = self.digest metadata["size"] = self.size metadata["annotations"] = self.extended_dict["annotations"] diff --git a/src/gardenlinux/oci/index.py b/src/gardenlinux/oci/index.py index 2b625e0a..8a523d95 100644 --- a/src/gardenlinux/oci/index.py +++ b/src/gardenlinux/oci/index.py @@ -9,6 +9,7 @@ from typing import Any, Dict from .image_manifest import ImageManifest +from .manifest import Manifest from .schemas import empty_index @@ -99,6 +100,9 @@ def append_manifest(self, manifest: Dict[str, Any]) -> None: image_manifest = ImageManifest(manifest) + if image_manifest.size < 1: + raise ValueError("Manifest to be added is empty") + existing_manifest_index = 0 for existing_manifest in self["manifests"]: @@ -122,4 +126,11 @@ def append_manifest(self, manifest: Dict[str, Any]) -> None: if len(self["manifests"]) > existing_manifest_index: self["manifests"].pop(existing_manifest_index) - self["manifests"].append(manifest) + index_manifest = Manifest() + index_manifest["mediaType"] = image_manifest["mediaType"] + index_manifest["digest"] = image_manifest.digest + index_manifest["size"] = image_manifest.size + index_manifest["annotations"] = image_manifest["annotations"] + index_manifest["platform"] = image_manifest.get("platform", {}) + + self["manifests"].append(index_manifest)