npm modules installed on a nodejs application are not being listed

Solution Verified - Updated -

Issue

npm modules installed on a nodejs application are not shown at :

npm ls 

or 

npm ls --json
  1. Create a nodejs application
  2. add a dependency/dependencies in package.json. For eg :
    "dependencies": {
        "yo": "1.x.x",
        "compass": "0.x",
        "bower": "1.x"
    },
  1. git add>commit>push, the output shows npm modules are installed.

  2. ssh to the application and run 'npm ls --json' or 'npm ls' it does not return the installed npm modules.

Environment

  • OpenShift Enterprise (OSE)

    • 1.x
    • 2.0
  • OpenShift Online (OSO)

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In
Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.