Skip to content

Commit ca8b2b7

Browse files
authored
Merge pull request #1525 from mythi/PR-2023-043
images: base image specific toybox config and version updates
2 parents e0c0bd6 + ad6c524 commit ca8b2b7

25 files changed

+432
-30
lines changed

build/docker/build-image.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ fi
3131

3232
BUILD_ARGS="${BUILD_ARGS} --build-arg FINAL_BASE=gcr.io/distroless/static"
3333
if [ -z "${BUILDER}" -o "${BUILDER}" = 'docker' -o "${BUILDER}" = 'podman' ] ; then
34-
${BUILDER} build --pull -t ${IMG}:${TAG} ${BUILD_ARGS} -f ${DOCKERFILE} .
34+
DOCKER_BUILDKIT=0 ${BUILDER} build --pull -t ${IMG}:${TAG} ${BUILD_ARGS} -f ${DOCKERFILE} .
3535
elif [ "${BUILDER}" = 'buildah' ] ; then
3636
BUILDAH_RUNTIME=runc buildah bud --pull-always -t ${IMG}:${TAG} ${BUILD_ARGS} -f ${DOCKERFILE} .
3737
else

build/docker/intel-deviceplugin-operator.Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ ARG CMD=operator
2525
## (see build-image.sh).
2626
## 2) and the default FINAL_BASE is primarily used to build Redhat Certified Openshift Operator container images that must be UBI based.
2727
## The RedHat build tool does not allow additional image build parameters.
28-
ARG FINAL_BASE=registry.access.redhat.com/ubi8-micro:latest
28+
ARG FINAL_BASE=registry.access.redhat.com/ubi9-micro:latest
2929
###
3030
##
3131
## GOLANG_BASE can be used to make the build reproducible by choosing an

build/docker/intel-dlb-initcontainer.Dockerfile

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
## (see build-image.sh).
2525
## 2) and the default FINAL_BASE is primarily used to build Redhat Certified Openshift Operator container images that must be UBI based.
2626
## The RedHat build tool does not allow additional image build parameters.
27-
ARG FINAL_BASE=registry.access.redhat.com/ubi8-micro:latest
27+
ARG FINAL_BASE=registry.access.redhat.com/ubi9-micro:latest
2828
###
2929
##
3030
## GOLANG_BASE can be used to make the build reproducible by choosing an
@@ -44,12 +44,14 @@ ARG TOYBOX_SHA256="3c31e235fe87e74e6c6cf7cd7299fcbffb0f4a4834dae607aa26bb4f15835
4444
ARG ROOT=/install_root
4545
RUN apt-get update && apt-get --no-install-recommends -y install musl musl-tools musl-dev
4646
SHELL ["/bin/bash", "-o", "pipefail", "-c"]
47+
ARG FINAL_BASE=registry.access.redhat.com/ubi9-micro:latest
4748
RUN curl -SL https://github.com/landley/toybox/archive/refs/tags/$TOYBOX_VERSION.tar.gz -o toybox.tar.gz \
4849
&& echo "$TOYBOX_SHA256 toybox.tar.gz" | sha256sum -c - \
4950
&& tar -xzf toybox.tar.gz \
5051
&& rm toybox.tar.gz \
5152
&& cd toybox-$TOYBOX_VERSION \
52-
&& KCONFIG_CONFIG=${DIR}/build/docker/toybox-config LDFLAGS="--static" CC=musl-gcc PREFIX=$ROOT V=2 make toybox install \
53+
&& KCONFIG_CONFIG=${DIR}/build/docker/toybox-config-$(echo ${FINAL_BASE} | xargs basename -s :latest) LDFLAGS="--static" CC=musl-gcc PREFIX=$ROOT/usr/bin V=2 make toybox install_flat \
54+
&& cd $ROOT && ln -fs usr/bin bin && cd - \
5355
&& install -D LICENSE $ROOT/licenses/toybox \
5456
&& cp -r /usr/share/doc/musl $ROOT/licenses/
5557
###

build/docker/intel-dlb-plugin.Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ ARG CMD=dlb_plugin
2525
## (see build-image.sh).
2626
## 2) and the default FINAL_BASE is primarily used to build Redhat Certified Openshift Operator container images that must be UBI based.
2727
## The RedHat build tool does not allow additional image build parameters.
28-
ARG FINAL_BASE=registry.access.redhat.com/ubi8-micro:latest
28+
ARG FINAL_BASE=registry.access.redhat.com/ubi9-micro:latest
2929
###
3030
##
3131
## GOLANG_BASE can be used to make the build reproducible by choosing an

build/docker/intel-dsa-plugin.Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ ARG CMD=dsa_plugin
2525
## (see build-image.sh).
2626
## 2) and the default FINAL_BASE is primarily used to build Redhat Certified Openshift Operator container images that must be UBI based.
2727
## The RedHat build tool does not allow additional image build parameters.
28-
ARG FINAL_BASE=registry.access.redhat.com/ubi8-micro:latest
28+
ARG FINAL_BASE=registry.access.redhat.com/ubi9-micro:latest
2929
###
3030
##
3131
## GOLANG_BASE can be used to make the build reproducible by choosing an

build/docker/intel-fpga-admissionwebhook.Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ ARG CMD=fpga_admissionwebhook
2525
## (see build-image.sh).
2626
## 2) and the default FINAL_BASE is primarily used to build Redhat Certified Openshift Operator container images that must be UBI based.
2727
## The RedHat build tool does not allow additional image build parameters.
28-
ARG FINAL_BASE=registry.access.redhat.com/ubi8-micro:latest
28+
ARG FINAL_BASE=registry.access.redhat.com/ubi9-micro:latest
2929
###
3030
##
3131
## GOLANG_BASE can be used to make the build reproducible by choosing an

build/docker/intel-fpga-initcontainer.Dockerfile

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
## (see build-image.sh).
2525
## 2) and the default FINAL_BASE is primarily used to build Redhat Certified Openshift Operator container images that must be UBI based.
2626
## The RedHat build tool does not allow additional image build parameters.
27-
ARG FINAL_BASE=registry.access.redhat.com/ubi8-micro:latest
27+
ARG FINAL_BASE=registry.access.redhat.com/ubi9-micro:latest
2828
###
2929
##
3030
## GOLANG_BASE can be used to make the build reproducible by choosing an
@@ -75,12 +75,14 @@ ARG TOYBOX_SHA256="3c31e235fe87e74e6c6cf7cd7299fcbffb0f4a4834dae607aa26bb4f15835
7575
ARG ROOT=/install_root
7676
RUN apt-get update && apt-get --no-install-recommends -y install musl musl-tools musl-dev
7777
SHELL ["/bin/bash", "-o", "pipefail", "-c"]
78+
ARG FINAL_BASE=registry.access.redhat.com/ubi9-micro:latest
7879
RUN curl -SL https://github.com/landley/toybox/archive/refs/tags/$TOYBOX_VERSION.tar.gz -o toybox.tar.gz \
7980
&& echo "$TOYBOX_SHA256 toybox.tar.gz" | sha256sum -c - \
8081
&& tar -xzf toybox.tar.gz \
8182
&& rm toybox.tar.gz \
8283
&& cd toybox-$TOYBOX_VERSION \
83-
&& KCONFIG_CONFIG=${DIR}/build/docker/toybox-config LDFLAGS="--static" CC=musl-gcc PREFIX=$ROOT V=2 make toybox install \
84+
&& KCONFIG_CONFIG=${DIR}/build/docker/toybox-config-$(echo ${FINAL_BASE} | xargs basename -s :latest) LDFLAGS="--static" CC=musl-gcc PREFIX=$ROOT/usr/bin V=2 make toybox install_flat \
85+
&& cd $ROOT && ln -fs usr/bin bin && cd - \
8486
&& install -D LICENSE $ROOT/licenses/toybox \
8587
&& cp -r /usr/share/doc/musl $ROOT/licenses/
8688
###

build/docker/intel-fpga-plugin.Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ ARG CMD=fpga_plugin
2525
## (see build-image.sh).
2626
## 2) and the default FINAL_BASE is primarily used to build Redhat Certified Openshift Operator container images that must be UBI based.
2727
## The RedHat build tool does not allow additional image build parameters.
28-
ARG FINAL_BASE=registry.access.redhat.com/ubi8-micro:latest
28+
ARG FINAL_BASE=registry.access.redhat.com/ubi9-micro:latest
2929
###
3030
##
3131
## GOLANG_BASE can be used to make the build reproducible by choosing an

build/docker/intel-gpu-fakedev.Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ ARG CMD=gpu_fakedev
2525
## (see build-image.sh).
2626
## 2) and the default FINAL_BASE is primarily used to build Redhat Certified Openshift Operator container images that must be UBI based.
2727
## The RedHat build tool does not allow additional image build parameters.
28-
ARG FINAL_BASE=registry.access.redhat.com/ubi8-micro:latest
28+
ARG FINAL_BASE=registry.access.redhat.com/ubi9-micro:latest
2929
###
3030
##
3131
## GOLANG_BASE can be used to make the build reproducible by choosing an

build/docker/intel-gpu-initcontainer.Dockerfile

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
## (see build-image.sh).
2525
## 2) and the default FINAL_BASE is primarily used to build Redhat Certified Openshift Operator container images that must be UBI based.
2626
## The RedHat build tool does not allow additional image build parameters.
27-
ARG FINAL_BASE=registry.access.redhat.com/ubi8-micro:latest
27+
ARG FINAL_BASE=registry.access.redhat.com/ubi9-micro:latest
2828
###
2929
##
3030
## GOLANG_BASE can be used to make the build reproducible by choosing an
@@ -58,12 +58,14 @@ ARG TOYBOX_SHA256="3c31e235fe87e74e6c6cf7cd7299fcbffb0f4a4834dae607aa26bb4f15835
5858
ARG ROOT=/install_root
5959
RUN apt-get update && apt-get --no-install-recommends -y install musl musl-tools musl-dev
6060
SHELL ["/bin/bash", "-o", "pipefail", "-c"]
61+
ARG FINAL_BASE=registry.access.redhat.com/ubi9-micro:latest
6162
RUN curl -SL https://github.com/landley/toybox/archive/refs/tags/$TOYBOX_VERSION.tar.gz -o toybox.tar.gz \
6263
&& echo "$TOYBOX_SHA256 toybox.tar.gz" | sha256sum -c - \
6364
&& tar -xzf toybox.tar.gz \
6465
&& rm toybox.tar.gz \
6566
&& cd toybox-$TOYBOX_VERSION \
66-
&& KCONFIG_CONFIG=${DIR}/build/docker/toybox-config LDFLAGS="--static" CC=musl-gcc PREFIX=$ROOT V=2 make toybox install \
67+
&& KCONFIG_CONFIG=${DIR}/build/docker/toybox-config-$(echo ${FINAL_BASE} | xargs basename -s :latest) LDFLAGS="--static" CC=musl-gcc PREFIX=$ROOT/usr/bin V=2 make toybox install_flat \
68+
&& cd $ROOT && ln -fs usr/bin bin && cd - \
6769
&& install -D LICENSE $ROOT/licenses/toybox \
6870
&& cp -r /usr/share/doc/musl $ROOT/licenses/
6971
###

0 commit comments

Comments
 (0)