Skip to content
This repository has been archived by the owner on Jun 12, 2022. It is now read-only.

Failing on typescript install (large modules?) #70

Open
lmeyerov opened this issue Oct 1, 2019 · 1 comment · May be fixed by #72
Open

Failing on typescript install (large modules?) #70

lmeyerov opened this issue Oct 1, 2019 · 1 comment · May be fixed by #72

Comments

@lmeyerov
Copy link

lmeyerov commented Oct 1, 2019

See: nodejs/node#29364

Steps to reproduce (from a docker that repeatedly fails):

ENV NODE_VERSION 12.11.0

 && set -x \
 && curl -fsSLO --compressed "https://nodejs.org/dist/v$NODE_VERSION/node-v$NODE_VERSION-linux-$ARCH.tar.xz" \
 && curl -fsSLO --compressed "https://nodejs.org/dist/v$NODE_VERSION/SHASUMS256.txt.asc" \
 && gpg --batch --decrypt --output SHASUMS256.txt SHASUMS256.txt.asc \
 && grep " node-v$NODE_VERSION-linux-$ARCH.tar.xz\$" SHASUMS256.txt | sha256sum -c - \
 && tar -xJf "node-v$NODE_VERSION-linux-$ARCH.tar.xz" -C /usr/local --strip-components=1 --no-same-owner \
 && rm "node-v$NODE_VERSION-linux-$ARCH.tar.xz" SHASUMS256.txt.asc SHASUMS256.txt \
 && ln -s /usr/local/bin/node /usr/local/bin/nodejs \
 && node --version \
&& npm i -g [email protected] \

Also failed on node 12.1.

cc @isaacs as it seems you have been active on npm\make-fetch-happen\cache.js and the lines in question..

@lmeyerov
Copy link
Author

lmeyerov commented Oct 1, 2019

Fun, narrowed it down to something reproducible around env flag READABLE_STREAM.

Dockerfile:

FROM ubuntu:bionic
  
RUN echo "============ NODE DEPS ========" \
 && apt update -y --fix-missing \
 && apt install -y build-essential curl \
 && mkdir -p ~/.gnupg && echo "disable-ipv6" >>  ~/.gnupg/dirmngr.conf


#ENV NODE_NO_WARNINGS 1
#ENV USE_LOCAL_USER "false"
ENV READABLE_STREAM "disable"
#ENV NO_UPDATE_NOTIFIER "true"

ENV NODE_VERSION 12.10.0

RUN echo "============ NODE ============="\
 && for key in \
    94AE36675C464D64BAFA68DD7434390BDBE9B9C5 \
    FD3A5288F042B6850C66B31F09FE44734EB7990E \
    71DCFD284A79C3B38668286BC97EC7A07EDE3FC1 \
    DD8F2338BAE7501E3DD5AC78C273792F7D83545D \
    C4F0DFFF4E8C1A8236409D08E73BC641CC11F4C8 \
    B9AE9905FFD7803F25714661B63B535A4C206CA9 \
    77984A986EBC2AA786BC0F66B01FBB92821C587A \
    8FCCA13FEF1D0C2E91008E09770F7A9A5AE15600 \
    4ED778F539E3634C779C87C6D7062848A1AB005C \
    A48C2BEE680E841632CD4E44F07496B3EB3C1762 \
    B9E2F5981AA6E0CD28160D9FF13993A75599653C \
  ; do \
    gpg --batch --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys "$key" || \
    gpg --batch --keyserver hkp://ipv4.pool.sks-keyservers.net --recv-keys "$key" || \
    gpg --batch --keyserver hkp://pgp.mit.edu:80 --recv-keys "$key" ; \
  done \
 && ARCH= && dpkgArch="$(dpkg --print-architecture)" \
 && case "${dpkgArch##*-}" in \
    amd64) ARCH='x64';; \
    ppc64el) ARCH='ppc64le';; \
    s390x) ARCH='s390x';; \
    arm64) ARCH='arm64';; \
    armhf) ARCH='armv7l';; \
    i386) ARCH='x86';; \
    *) echo "unsupported architecture"; exit 1 ;; \
 esac \
 && set -x \
 && curl -fsSLO --compressed "https://nodejs.org/dist/v$NODE_VERSION/node-v$NODE_VERSION-linux-$ARCH.tar.xz" \
 && curl -fsSLO --compressed "https://nodejs.org/dist/v$NODE_VERSION/SHASUMS256.txt.asc" \
 && gpg --batch --decrypt --output SHASUMS256.txt SHASUMS256.txt.asc \
 && grep " node-v$NODE_VERSION-linux-$ARCH.tar.xz\$" SHASUMS256.txt | sha256sum -c - \
 && tar -xJf "node-v$NODE_VERSION-linux-$ARCH.tar.xz" -C /usr/local --strip-components=1 --no-same-owner \
 && rm "node-v$NODE_VERSION-linux-$ARCH.tar.xz" SHASUMS256.txt.asc SHASUMS256.txt \
 && ln -s /usr/local/bin/node /usr/local/bin/nodejs \
 && node --version \
 && npm --version \
 && echo "============== NODE INSTALLED ============"

RUN echo "======= typescript ==========" \
&& npm i -g [email protected] \
&& which tsc && tsc --version

Trigger: sudo docker build -t mytest:1 -f ubuntu.Dockerfile .

If you comment out READABLE_STREAM, it works.

adiktofsugar added a commit to adiktofsugar/make-fetch-happen that referenced this issue Oct 21, 2019
@adiktofsugar adiktofsugar linked a pull request Oct 21, 2019 that will close this issue
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant