Skip to content

Commit c69212e

Browse files
committed
Remove symlinks that do not exists
Add symlinks to 24-minimal container to allow testing NodeJS is not installed by default Signed-off-by: Petr "Stone" Hracek <phracek@redhat.com>
1 parent 9960668 commit c69212e

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

24-minimal/Dockerfile.rhel10

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,9 @@ 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+
ln -s /usr/bin/node-$NODEJS_VERSION /usr/bin/node && \
55+
ln -s /usr/bin/npm-$NODEJS_VERSION /usr/bin/npm && \
56+
ln -s /usr/bin/npx-$NODEJS_VERSION /usr/bin/npx && \
5457
node -v | grep -qe "^v$NODEJS_VERSION\." && echo "Found VERSION $NODEJS_VERSION" && \
5558
microdnf clean all && \
5659
rm -rf /mnt/rootfs/var/cache/* /mnt/rootfs/var/log/dnf* /mnt/rootfs/var/log/yum.*

24/Dockerfile.rhel10

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -56,9 +56,9 @@ LABEL summary="$SUMMARY" \
5656
RUN INSTALL_PKGS="make gcc gcc-c++ git openssl-devel nodejs$NODEJS_VERSION nodejs-nodemon nodejs$NODEJS_VERSION-npm nss_wrapper-libs which" && \
5757
dnf install -y --setopt=tsflags=nodocs $INSTALL_PKGS && \
5858
rpm -V $INSTALL_PKGS && \
59-
rm /usr/bin/node && ln -s /usr/bin/node-$NODEJS_VERSION /usr/bin/node && \
60-
rm /usr/bin/npm && ln -s /usr/bin/npm-$NODEJS_VERSION /usr/bin/npm && \
61-
rm /usr/bin/npx && ln -s /usr/bin/npx-$NODEJS_VERSION /usr/bin/npx && \
59+
ln -s /usr/bin/node-$NODEJS_VERSION /usr/bin/node && \
60+
ln -s /usr/bin/npm-$NODEJS_VERSION /usr/bin/npm && \
61+
ln -s /usr/bin/npx-$NODEJS_VERSION /usr/bin/npx && \
6262
node -v | grep -qe "^v$NODEJS_VERSION\." && echo "Found VERSION $NODEJS_VERSION" && \
6363
dnf -y clean all --enablerepo='*'
6464

0 commit comments

Comments
 (0)