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

strange behavior on npm install from git repository under docker #20362

Open
3 of 14 tasks
spike008t opened this issue Apr 18, 2018 · 0 comments
Open
3 of 14 tasks

strange behavior on npm install from git repository under docker #20362

spike008t opened this issue Apr 18, 2018 · 0 comments

Comments

@spike008t
Copy link

spike008t commented Apr 18, 2018

I'm opening this issue because:

  • npm is crashing.
  • npm is producing an incorrect install.
  • npm is doing something I don't understand.
  • npm is producing incorrect or undesirable behavior.
  • Other (see below for feature requests):

What's going wrong?

So i do have a really strange issue, under mac/windows/linux host, when i install a package based on typescript from github, I do have in this package the out folder (build folder).

Below is on the docker host:

pkhim@vsts-build-agent:/tmp/test$ uname -a
Linux vsts-build-agent 4.13.0-1011-azure #14-Ubuntu SMP Thu Feb 15 16:15:39 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux
pkhim@vsts-build-agent:/tmp/test$ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 16.04.4 LTS
Release:        16.04
Codename:       xenial
pkhim@vsts-build-agent:/tmp/test$ node -v
v8.11.1
pkhim@vsts-build-agent:/tmp/test$ npm -v
5.8.0
pkhim@vsts-build-agent:/tmp/test$ npm install Microsoft/ApplicationInsights-node.js
npm WARN saveError ENOENT: no such file or directory, open '/tmp/test/package.json'
npm notice created a lockfile as package-lock.json. You should commit this file.
npm WARN enoent ENOENT: no such file or directory, open '/tmp/test/package.json'
npm WARN test No description
npm WARN test No repository field.
npm WARN test No README data
npm WARN test No license field.

+ applicationinsights@1.0.2
added 5 packages from 3 contributors in 30.338s
pkhim@vsts-build-agent:/tmp/test$ ls node_modules/applicationinsights/
LICENSE  out  package.json  README.md

No problem at all, but when I use docker image node:8 (any image...), I do not have the out folder...

pkhim@vsts-build-agent:/tmp/test# docker run --rm -it node:8 bash
root@706b98e5ea00:/tmp/test# uname -a
Linux 706b98e5ea00 4.13.0-1011-azure #14-Ubuntu SMP Thu Feb 15 16:15:39 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux
root@706b98e5ea00:/tmp/test# lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 16.04.4 LTS
Release:        16.04
Codename:       xenial
root@706b98e5ea00:/tmp/test# node -v
v8.11.1
root@706b98e5ea00:/tmp/test# npm -v
5.8.0
root@706b98e5ea00:/tmp/test# npm install Microsoft/ApplicationInsights-node.js
npm WARN saveError ENOENT: no such file or directory, open '/tmp/test/package.json'
npm notice created a lockfile as package-lock.json. You should commit this file.
npm WARN enoent ENOENT: no such file or directory, open '/tmp/test/package.json'
npm WARN test No description
npm WARN test No repository field.
npm WARN test No README data
npm WARN test No license field.

+ applicationinsights@1.0.2
added 5 packages from 3 contributors in 9.632s
root@706b98e5ea00:/tmp/test# ls node_modules/applicationinsights/
LICENSE  README.md  package.json

I've also try to downgrade npm to 5.6.0 event 5.4.0, same things....
I do not have this problem under yarn

How can the CLI team reproduce the problem?

npm install Microsoft/ApplicationInsights-node.js
ls node_modules/applicationinsights/

Check if out folder is present

supporting information:

  • npm -v prints: 5.8.0
  • node -v prints: 8.11.1
  • npm config get registry prints: https://registry.npmjs.org/
  • Windows, OS X/macOS, or Linux?: Linux (docker)
  • Network issues:
    • Geographic location where npm was run:
    • I use a proxy to connect to the npm registry.
    • I use a proxy to connect to the web.
    • I use a proxy when downloading Git repos.
    • I access the npm registry via a VPN
    • I don't use a proxy, but have limited or unreliable internet access.
  • Container:
    • I develop using Vagrant on Windows.
    • I develop using Vagrant on OS X or Linux.
    • I develop / deploy using Docker.
    • I deploy to a PaaS (Triton, Heroku).
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant