question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Fail to npm install in docker when using nightly-master (extend base docker image)

See original GitHub issue

Your Environment

  • verdaccio version: nightly-master (docker)
  • node version [12.x.x, 14.x.x]: 14.18.1
  • package manager: [npm@7, pnpm@6, yarn@2]: npm 6.14.15
  • os: [mac, windows@10, linux] Ubuntu on WSL2
  • platform: [npm, docker, helm, other] docker

Describe the bug

Unable to run npm install in nightly-master docker.

To Reproduce Run docker build for the following Dockerfile

FROM verdaccio/verdaccio:nightly-master

USER root

ENV NODE_ENV=production

RUN npm install --verbose
RUN npm install verdaccio-aws-s3-storage

Expected behavior

Installs successfully. Note: it works when using older docker images (verdaccio:4)

Environment information

N/A (doesn’t reach that stage)

Debugging output

Docker build output (from the npm install --verbose part)

#4 0.394 npm info it worked if it ends with ok
#4 0.395 npm verb cli [ '/usr/local/bin/node', '/usr/local/bin/npm', 'install', '--verbose' ]
#4 0.395 npm info using npm@6.14.15
#4 0.396 npm info using node@v14.18.1
#4 0.396 npm verb config Skipping project config: /opt/verdaccio/.npmrc. (matches userconfig)
#4 0.573 npm verb npm-session 5cbd7daf9aa3a6ff
#4 0.613 npm info lifecycle verdaccio-dev@~preinstall: verdaccio-dev@
#4 1.233 npm timing stage:loadCurrentTree Completed in 619ms
#4 1.237 npm timing stage:loadIdealTree:cloneCurrentTree Completed in 4ms
#4 1.323 npm timing stage:loadIdealTree:loadShrinkwrap Completed in 85ms
#4 1.325 npm timing stage:rollbackFailedOptional Completed in 0ms
#4 1.325 npm timing stage:runTopLevelLifecycles Completed in 734ms
#4 1.414 npm verb stack Error: Unsupported URL Type "workspace:": workspace:*
#4 1.414 npm verb stack     at unsupportedURLType (/usr/local/lib/node_modules/npm/node_modules/npm-package-arg/npa.js:200:15)
#4 1.414 npm verb stack     at fromURL (/usr/local/lib/node_modules/npm/node_modules/npm-package-arg/npa.js:258:13)
#4 1.414 npm verb stack     at Function.resolve (/usr/local/lib/node_modules/npm/node_modules/npm-package-arg/npa.js:77:12)
#4 1.414 npm verb stack     at /usr/local/lib/node_modules/npm/lib/install/deps.js:493:20
#4 1.414 npm verb stack     at Array.map (<anonymous>)
#4 1.415 npm verb stack     at /usr/local/lib/node_modules/npm/lib/install/deps.js:492:47
#4 1.415 npm verb stack     at tryCatcher (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/util.js:16:23)
#4 1.415 npm verb stack     at Promise._settlePromiseFromHandler (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/promise.js:517:31)
#4 1.415 npm verb stack     at Promise._settlePromise (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/promise.js:574:18)
#4 1.416 npm verb stack     at Promise._settlePromiseCtx (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/promise.js:611:10)
#4 1.416 npm verb stack     at _drainQueueStep (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/async.js:142:12)
#4 1.416 npm verb stack     at _drainQueue (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/async.js:131:9)
#4 1.416 npm verb stack     at Async._drainQueues (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/async.js:147:5)
#4 1.417 npm verb stack     at Immediate.Async.drainQueues [as _onImmediate] (/usr/local/lib/node_modules/npm/node_modules/bluebird/js/release/async.js:17:14)
#4 1.417 npm verb stack     at processImmediate (internal/timers.js:464:21)
#4 1.417 npm verb cwd /opt/verdaccio
#4 1.418 npm verb Linux 5.4.72-microsoft-standard-WSL2
#4 1.419 npm verb argv "/usr/local/bin/node" "/usr/local/bin/npm" "install" "--verbose"
#4 1.419 npm verb node v14.18.1
#4 1.419 npm verb npm  v6.14.15
#4 1.420 npm ERR! code EUNSUPPORTEDPROTOCOL
#4 1.431 npm ERR! Unsupported URL Type "workspace:": workspace:*
#4 1.431 npm verb exit [ 1, true ]

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:2
  • Comments:7 (4 by maintainers)

github_iconTop GitHub Comments

0reactions
juanpicadocommented, Jul 25, 2022

Indeed. Looks like a problem on my npm client. Sorry for bothering you.

No worries, 😃 happy to help.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Npm install doesn't complete inside docker container
Running npm install on the host system using the same package.json completes ... Most specific failure is: No error was detected
Read more >
npm - Install node_modules inside Docker container and ...
I'd like my node_modules inside the Docker container to be synchronized with the host. Please, take into account that I want: to install...
Read more >
10 best practices to containerize Node.js web applications ...
Follow these 10 steps to build optimized Node.js web applications with Docker: Use explicit and deterministic Docker base image tags; Install ...
Read more >
Convenience images - CircleCI
The next-gen convenience images in the following sections are based on the most recent Ubuntu LTS Docker images and installed with the base...
Read more >
Use kaniko to build Docker images - GitLab Docs
kaniko is a tool to build container images from a Dockerfile, inside a ... base image registry.gitlab.example.com/group/docker-image error building image: ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found