Skip to content

Commit 00f5433

Browse files
committed
Remove module from 22-minimal/Dockerfile.rhel10
Pull image ubi10/nodejs-22 in case testing container NodeJS-22 minimal Signed-off-by: Petr "Stone" Hracek <[email protected]>
1 parent 1996c74 commit 00f5433

File tree

2 files changed

+10
-6
lines changed

2 files changed

+10
-6
lines changed

22-minimal/Dockerfile.rhel10

-2
Original file line numberDiff line numberDiff line change
@@ -51,8 +51,6 @@ LABEL summary="$SUMMARY" \
5151

5252
# nodejs-full-i18n is included for error strings
5353
RUN INSTALL_PKGS="nodejs nodejs-nodemon nodejs-full-i18n npm findutils tar which" && \
54-
microdnf -y module disable nodejs && \
55-
microdnf -y module enable nodejs:$NODEJS_VERSION && \
5654
microdnf -y --nodocs --setopt=install_weak_deps=0 install $INSTALL_PKGS && \
5755
node -v | grep -qe "^v$NODEJS_VERSION\." && echo "Found VERSION $NODEJS_VERSION" && \
5856
microdnf clean all && \

test/run-minimal

+10-4
Original file line numberDiff line numberDiff line change
@@ -90,16 +90,22 @@ prepare app
9090
check_prep_result $? app || exit
9191
echo "Testing the production image build"
9292

93-
FULL_IMAGE=${FULL_IMAGE:-${IMAGE_NAME//-minimal:1/}}
93+
FULL_IMAGE=${FULL_IMAGE:-${IMAGE_NAME//-minimal:latest/}}
9494
# if FULL_IMAGE is not found, try to pull it, if that does not work, try to pull ubi9 one
9595
if [ -z "$(docker images -q "$FULL_IMAGE")" ] ; then
9696
echo "Image $FULL_IMAGE not found, trying to pull $FULL_IMAGE from registry"
9797
docker pull "$FULL_IMAGE"
9898
fi
9999
if [ -z "$(docker images -q "$FULL_IMAGE")" ] ; then
100-
echo "Image $FULL_IMAGE still not found, trying to use ubi9/nodejs-${VERSION//-minimal/}:latest and pull it"
101-
FULL_IMAGE="ubi9/nodejs-${VERSION//-minimal/}:latest"
102-
docker pull "$FULL_IMAGE"
100+
if [[ "$OS" == "rhel9" ]]; then
101+
echo "Image $FULL_IMAGE still not found, trying to use ubi9/nodejs-${VERSION//-minimal/}:latest and pull it"
102+
FULL_IMAGE="ubi9/nodejs-${VERSION//-minimal/}:latest"
103+
docker pull "$FULL_IMAGE"
104+
elif [[ "$OS" == "rhel10" ]]; then
105+
echo "Image $FULL_IMAGE still not found, trying to use ubi10/nodejs-${VERSION//-minimal/}:latest and pull it"
106+
FULL_IMAGE="ubi10/nodejs-${VERSION//-minimal/}:latest"
107+
docker pull "$FULL_IMAGE"
108+
fi
103109
fi
104110
if [ -z "$(docker images -q "$FULL_IMAGE")" ] ; then
105111
echo "Image $FULL_IMAGE could not be found nor pulled, giving up."

0 commit comments

Comments
 (0)