-
Notifications
You must be signed in to change notification settings - Fork 145
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use image "stream10-development" for now, after the release we should remove the "-development" suffix. This also removes the `rpmlint` package from the installation as it's no longer included for CentOS Stream 10 ("CS10"); - https://issues.redhat.com/browse/CS-2451 - https://issues.redhat.com/browse/CS-2453 Signed-off-by: Romain Geissler <[email protected]> Signed-off-by: Sebastiaan van Stijn <[email protected]>
- Loading branch information
1 parent
6547a6f
commit d130e47
Showing
3 changed files
with
37 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
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
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,35 @@ | ||
# syntax=docker/dockerfile:1 | ||
|
||
ARG GO_IMAGE=golang:latest | ||
ARG DISTRO=centos | ||
ARG SUITE=10 | ||
ARG BUILD_IMAGE=quay.io/centos/${DISTRO}:stream${SUITE}-development | ||
|
||
FROM ${GO_IMAGE} AS golang | ||
|
||
FROM ${BUILD_IMAGE} | ||
ENV GOPROXY=https://proxy.golang.org|direct | ||
ENV GO111MODULE=off | ||
ENV GOPATH=/go | ||
ENV GOTOOLCHAIN=local | ||
ENV PATH=$PATH:/usr/local/go/bin:$GOPATH/bin | ||
ENV AUTO_GOPATH=1 | ||
ENV DOCKER_BUILDTAGS=exclude_graphdriver_btrfs | ||
ARG DISTRO | ||
ARG SUITE | ||
ENV DISTRO=${DISTRO} | ||
ENV SUITE=${SUITE} | ||
|
||
# RHEL8 / CentOS 8 changed behavior and no longer "rpm --import" or | ||
# "rpmkeys --import"as part of rpm package's %post scriplet. See | ||
# https://forums.centos.org/viewtopic.php?f=54&t=72574, and | ||
# https://access.redhat.com/solutions/3720351 | ||
RUN rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-centosofficial-SHA256 | ||
RUN dnf install -y rpm-build dnf-plugins-core | ||
RUN dnf config-manager --set-enabled crb | ||
|
||
COPY --link SPECS /root/rpmbuild/SPECS | ||
RUN dnf builddep -y /root/rpmbuild/SPECS/*.spec | ||
COPY --link --from=golang /usr/local/go /usr/local/go | ||
WORKDIR /root/rpmbuild | ||
ENTRYPOINT ["/bin/rpmbuild"] |