Skip to content

Commit

Permalink
compare old image and new image rpms
Browse files Browse the repository at this point in the history
  • Loading branch information
Perpixel committed Oct 14, 2024
1 parent 1dc5c92 commit 0742413
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/build-system.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ jobs:
REPO=${{ github.repository }}
echo "IMAGE_NAME=nvidia-${REPO##*/}" >> $GITHUB_ENV
echo "FEDORA_VERSION=${{ matrix.version }}" >> $GITHUB_ENV
echo "NVIDIA_VERSION"=$(<nvidia_version.txt) >> $GITHUB_ENV
- name: Generate tags
id: generate-tags
Expand Down Expand Up @@ -106,6 +107,7 @@ jobs:
TARGET_IMAGE_NAME=${{ env.IMAGE_NAME }}
BASE_IMAGE=${{ env.BASE_IMAGE }}
FEDORA_VERSION=${{ env.FEDORA_VERSION }}
NVIDIA_VERSION=${{ env.NVIDIA_VERSION }}
extra-args: |
--no-cache
--pull=always
Expand Down
5 changes: 3 additions & 2 deletions Containerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
ARG TARGET_IMAGE_NAME="${TARGET_IMAGE_NAME}"
ARG BASE_IMAGE="${BASE_IMAGE}"
ARG FEDORA_VERSION="${FEDORA_VERSION}"
ARG NVIDIA_VERSION="${NVIDIA_VERSION}"

# Collect current packages

Expand All @@ -13,7 +14,7 @@ RUN rpm -qa >/packages.old
# them available to the final image in this container.i

FROM ${BASE_IMAGE}:${FEDORA_VERSION} as nvidia-builder
RUN NVIDIA_VERSION=$(<nvidia-version.txt)
ARG NVIDIA_VERSION="${NVIDIA_VERSION}"
COPY build_files/scripts /tmp/scripts
RUN rpm-ostree cliwrap install-to-root / \
&& /tmp/scripts/build-nvidia-drv.sh
Expand All @@ -22,7 +23,7 @@ RUN rpm-ostree cliwrap install-to-root / \
#

FROM ${BASE_IMAGE}:${FEDORA_VERSION}
RUN NVIDIA_VERSION=$(<nvidia-version.txt)
ARG NVIDIA_VERSION="${NVIDIA_VERSION}"
COPY build_files/scripts /tmp/scripts
COPY --from=nvidia-builder /build/modules /tmp/nvidia-modules
COPY --from=packages-list /packages.old /tmp/build/packages.old
Expand Down

0 comments on commit 0742413

Please sign in to comment.