I am creating a new image of my backend on Docker, and the process have taken 1 hour and yet to be done.
Dockerfile:
FROM node:20.13.1-alpine3.19
RUN apk --no-cache add curl
EXPOSE 6500
RUN mkdir -p /app
WORKDIR /app
COPY . ./
RUN curl -L https://unpkg.com/@pnpm/self-installer | node
RUN pnpm install
ENTRYPOINT ["pnpm", "dev"]
then the process is fairly fast, up until this point, then it just stops there, nothing happening.
Progress: resolved 329, reused 0, downloaded 306, added 212
Progress: resolved 329, reused 0, downloaded 306, added 306, done
.../node_modules/@prisma/engines postinstall$ node scripts/postinstall.js
.../[email protected]/node_modules/esbuild postinstall$ node install.js
.../[email protected]/node_modules/bcrypt install$ node-pre-gyp install --fallback-to-build
.../node_modules/puppeteer postinstall$ node install.js
.../[email protected]/node_modules/esbuild postinstall: Done
.../[email protected]/node_modules/bcrypt install: node-pre-gyp info it worked if it ends with ok
.../[email protected]/node_modules/bcrypt install: node-pre-gyp info using [email protected]
.../[email protected]/node_modules/bcrypt install: node-pre-gyp info using [email protected] | linux | x64
.../[email protected]/node_modules/bcrypt install: node-pre-gyp info check checked for "/app/node_modules/.pnpm/[email protected]/node_modules/bcrypt/lib/binding/napi-v3/bcrypt_lib.node" (not found)
.../[email protected]/node_modules/bcrypt install: node-pre-gyp http GET https://github.com/kelektiv/node.bcrypt.js/releases/download/v5.1.1/bcrypt_lib-v5.1.1-napi-v3-linux-x64-musl.tar.gz
.../[email protected]/node_modules/bcrypt install: node-pre-gyp info install unpacking napi-v3/bcrypt_lib.node
.../[email protected]/node_modules/bcrypt install: node-pre-gyp info extracted file count: 1
.../[email protected]/node_modules/bcrypt install: [bcrypt] Success: "/app/node_modules/.pnpm/[email protected]/node_modules/bcrypt/lib/binding/napi-v3/bcrypt_lib.node" is installed via remote
.../[email protected]/node_modules/bcrypt install: node-pre-gyp info ok
.../[email protected]/node_modules/bcrypt install: Done
.../node_modules/@prisma/engines postinstall: Done
My docker stats
also shows that extremely slow Network I/O, around 100kB/s.