Skip to content

Commit f70850f

Browse files
committed
Create symlinks also in rhel10/c10s minimal to have node binary without a prefix
1 parent 375fe31 commit f70850f

File tree

2 files changed

+8
-2
lines changed

2 files changed

+8
-2
lines changed

24-minimal/Dockerfile.c10s

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,8 +51,11 @@ LABEL summary="$SUMMARY" \
5151
# nodejs-full-i18n is included for error strings
5252
RUN INSTALL_PKGS="nodejs$NODEJS_VERSION nodejs-nodemon nodejs$NODEJS_VERSION-full-i18n nodejs$NODEJS_VERSION-npm findutils tar which" && \
5353
dnf -y --nodocs --setopt=install_weak_deps=0 install $INSTALL_PKGS && \
54-
node-24 -v | grep -qe "^v$NODEJS_VERSION\." && echo "Found VERSION $NODEJS_VERSION" && \
5554
dnf clean all && \
55+
ln -s /usr/bin/node-$NODEJS_VERSION /usr/bin/node && \
56+
ln -s /usr/bin/npm-$NODEJS_VERSION /usr/bin/npm && \
57+
ln -s /usr/bin/npx-$NODEJS_VERSION /usr/bin/npx && \
58+
node -v | grep -qe "^v$NODEJS_VERSION\." && echo "Found VERSION $NODEJS_VERSION" && \
5659
rm -rf /mnt/rootfs/var/cache/* /mnt/rootfs/var/log/dnf* /mnt/rootfs/var/log/yum.*
5760

5861
COPY ./s2i/bin/ /usr/libexec/s2i

24-minimal/Dockerfile.rhel10

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,8 +51,11 @@ LABEL summary="$SUMMARY" \
5151
# nodejs-full-i18n is included for error strings
5252
RUN INSTALL_PKGS="nodejs$NODEJS_VERSION nodejs-nodemon nodejs$NODEJS_VERSION-full-i18n nodejs$NODEJS_VERSION-npm findutils tar which" && \
5353
microdnf -y --nodocs --setopt=install_weak_deps=0 install $INSTALL_PKGS && \
54-
node -v | grep -qe "^v$NODEJS_VERSION\." && echo "Found VERSION $NODEJS_VERSION" && \
5554
microdnf clean all && \
55+
ln -s /usr/bin/node-$NODEJS_VERSION /usr/bin/node && \
56+
ln -s /usr/bin/npm-$NODEJS_VERSION /usr/bin/npm && \
57+
ln -s /usr/bin/npx-$NODEJS_VERSION /usr/bin/npx && \
58+
node -v | grep -qe "^v$NODEJS_VERSION\." && echo "Found VERSION $NODEJS_VERSION" && \
5659
rm -rf /mnt/rootfs/var/cache/* /mnt/rootfs/var/log/dnf* /mnt/rootfs/var/log/yum.*
5760

5861
COPY ./s2i/bin/ /usr/libexec/s2i

0 commit comments

Comments
 (0)