-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
48 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
24 changes: 24 additions & 0 deletions
24
demo/builder-support/dockerfiles/Dockerfile.target.rocky-9
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# First do the source builds | ||
@INCLUDE Dockerfile.target.sdist | ||
|
||
# This defines the distribution base layer | ||
# Put only the bare minimum of common commands here, without dev tools | ||
FROM rockylinux:9 as dist-base | ||
ARG BUILDER_CACHE_BUSTER= | ||
#RUN dnf install -y epel-release | ||
# Python 3.4+ is needed for the builder helpers | ||
RUN dnf install -y /usr/bin/python3 | ||
RUN dnf install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-9.noarch.rpm | ||
RUN dnf install -y dnf-plugins-core | ||
RUN dnf config-manager --set-enabled crb | ||
|
||
# Do the actual rpm build | ||
@INCLUDE Dockerfile.rpmbuild | ||
|
||
# Generate provenance | ||
RUN /build/builder/helpers/generate-dnf-provenance.py /dist/rpm-provenance.json | ||
|
||
# Do a test install and verify | ||
# Can be skipped with skiptests=1 in the environment | ||
@EXEC [ "$skiptests" = "" ] && include Dockerfile.rpmtest | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
#!/bin/sh | ||
# Test if rocky-9 RPM builds are reproducible | ||
# Must be run from demo dir | ||
|
||
set -ex | ||
|
||
# First build | ||
./builder/build.sh -B MYCOOLARG=iLikeTests rocky-9 | ||
|
||
# Record hashes | ||
sha256sum \ | ||
builder/tmp/latest/rocky-9/dist/noarch/*.rpm \ | ||
builder/tmp/latest/sdist/*.tar.gz \ | ||
> /tmp/sha256sum.txt | ||
|
||
# Second build after cleaning and adding a file to invalidate the build context | ||
rm -rf ./builder/tmp/latest/rocky-9 | ||
rm -rf ./builder/tmp/latest/sdist | ||
./builder/build.sh -B MYCOOLARG=iLikeTests -b build-again rocky-9 | ||
|
||
# Check hashes, should be identical | ||
sha256sum -c /tmp/sha256sum.txt | ||
|