Global install of http-proxy is not found #438

kretz opened this Issue Jun 28, 2013 · 2 comments


None yet

3 participants

kretz commented Jun 28, 2013

I tried to use http-proxy today using a global install, but the module could not be found. A local install worked fine. FYI I was running a simplified node script without any packages, just a web-server.js file.

npm install -g http-proxy
-> Error: Cannot find module 'http-proxy'

npm install http-proxy

Thanks for a great module!

ruquay commented Jul 1, 2013

Is the installation failing? The error message you're posting looks like it comes from trying to require() a module that you don't have. You probably want to install it locally.
From the npm documentation:

  • Install it locally if you´re going to require() it.
  • Install it globally if you´re going to run it on the command line.
  • If you need both, then install it in both places, or use npm link.
mmalecki commented Jul 2, 2013

This is how node module works. @ruquay is right here.

@mmalecki mmalecki closed this Jul 2, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment